executor: fix double free of MountOptions
authorLuca Boccassi <bluca@debian.org>
Thu, 19 Oct 2023 11:24:19 +0000 (12:24 +0100)
committerLuca Boccassi <luca.boccassi@gmail.com>
Thu, 19 Oct 2023 13:24:55 +0000 (14:24 +0100)
commit9dc6a6af28d93f7bf5e0c07cccb34d41bb265b32
treeff58c646627f74b39995005c2880a0c9b8702905
parent41204a6d743eba1db8b4cd6d94a05ffffe862445
executor: fix double free of MountOptions

This list is owned by ExecContext, which is cleaned up when sd-executor
fails, but it is also cleaned up when namespace setup exits, so we get
a double free.

Fixes https://github.com/systemd/systemd/issues/29610

Follow-up for bb5232b6a3
src/core/namespace.c