From f0a95a2c6d64436611bca31de1f7662a4066695c Mon Sep 17 00:00:00 2001 From: Lennart Poettering Date: Mon, 25 Mar 2019 16:57:55 +0100 Subject: [PATCH] mount-util: use set_put_strdup() where appropriate --- src/shared/mount-util.c | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/src/shared/mount-util.c b/src/shared/mount-util.c index 8af90a5..72cf6c4 100644 --- a/src/shared/mount-util.c +++ b/src/shared/mount-util.c @@ -250,11 +250,7 @@ int bind_remount_recursive_with_mountinfo(const char *prefix, bool ro, char **bl log_debug("Made top-level directory %s a mount point.", prefix); - x = strdup(cleaned); - if (!x) - return -ENOMEM; - - r = set_consume(done, x); + r = set_put_strdup(done, cleaned); if (r < 0) return r; } -- 2.7.4