From: Yu Watanabe Date: Sat, 15 Aug 2020 09:26:23 +0000 (+0900) Subject: core: use strv_free_and_replace() at one more place X-Git-Tag: v247-rc1~232 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=8cc53fae3606cf65231b9f50e707c323c81e8b80;p=thirdparty%2Fsystemd.git core: use strv_free_and_replace() at one more place --- diff --git a/src/core/device.c b/src/core/device.c index 31aa3341c2b..595b009cd93 100644 --- a/src/core/device.c +++ b/src/core/device.c @@ -441,10 +441,7 @@ static int device_add_udev_wants(Unit *u, sd_device *dev) { } } - strv_free(d->wants_property); - d->wants_property = TAKE_PTR(added); - - return 0; + return strv_free_and_replace(d->wants_property, added); } static bool device_is_bound_by_mounts(Device *d, sd_device *dev) {