diff options
author | Yu Watanabe <watanabe.yu+github@gmail.com> | 2022-09-16 09:26:07 +0900 |
---|---|---|
committer | Lennart Poettering <lennart@poettering.net> | 2022-09-16 13:05:51 +0200 |
commit | f91c23f78525d2b429bc7c5b6ef597241864d3f3 (patch) | |
tree | 1d9c4a4c6a41df8fd6570709a25859d20cca271b /src | |
parent | 05d5db01b75f3c2d817b6d8780cf6a5ddcab6c67 (diff) | |
download | systemd-f91c23f78525d2b429bc7c5b6ef597241864d3f3.tar.gz |
sd-device-monitor: do not trigger assertion when uid_map is not empty
Follow-up for c0aa23cf1ed4b3cbbcaf8b19d47e6e29dc28c9a0.
Diffstat (limited to 'src')
-rw-r--r-- | src/libsystemd/sd-device/device-monitor.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/libsystemd/sd-device/device-monitor.c b/src/libsystemd/sd-device/device-monitor.c index 8b1b01ee0f..072c6b94d3 100644 --- a/src/libsystemd/sd-device/device-monitor.c +++ b/src/libsystemd/sd-device/device-monitor.c @@ -469,6 +469,7 @@ static bool check_sender_uid(sd_device_monitor *m, uid_t uid) { return true; if (m->n_uid_range == SIZE_MAX) { + m->n_uid_range = 0; r = uid_range_load_userns(&m->mapped_userns_uid_range, &m->n_uid_range, NULL); if (r < 0) log_monitor_errno(m, r, "Failed to load UID ranges mapped to the current user namespace, ignoring: %m"); |