}
static int mount_process_proc_self_mountinfo(Manager *m) {
- _cleanup_set_free_free_ Set *around = NULL, *gone = NULL;
+ _cleanup_set_free_ Set *around = NULL, *gone = NULL;
const char *what;
int r;
* existed. */
if (mount->from_proc_self_mountinfo &&
- mount->parameters_proc_self_mountinfo.what) {
-
+ mount->parameters_proc_self_mountinfo.what)
/* Remember that this device might just have disappeared */
- if (set_ensure_allocated(&gone, &path_hash_ops) < 0 ||
- set_put_strdup(&gone, mount->parameters_proc_self_mountinfo.what) < 0)
+ if (set_put_strdup_full(&gone, &path_hash_ops_free, mount->parameters_proc_self_mountinfo.what) < 0)
log_oom(); /* we don't care too much about OOM here... */
- }
mount->from_proc_self_mountinfo = false;
assert_se(update_parameters_proc_self_mountinfo(mount, NULL, NULL, NULL) >= 0);
if (mount_is_mounted(mount) &&
mount->from_proc_self_mountinfo &&
- mount->parameters_proc_self_mountinfo.what) {
+ mount->parameters_proc_self_mountinfo.what)
/* Track devices currently used */
-
- if (set_ensure_allocated(&around, &path_hash_ops) < 0 ||
- set_put_strdup(&around, mount->parameters_proc_self_mountinfo.what) < 0)
+ if (set_put_strdup_full(&around, &path_hash_ops_free, mount->parameters_proc_self_mountinfo.what) < 0)
log_oom();
- }
/* Reset the flags for later calls */
mount->proc_flags = 0;