*: convert amenable fdopen calls to take_fdopen
Mechanical change to eliminate some cruft by using the
new take_fdopen{_unlocked}() wrappers where trivial.
This commit is contained in:
@@ -1280,10 +1280,9 @@ static int unit_file_load(
|
||||
if (r < 0)
|
||||
return r;
|
||||
|
||||
f = fdopen(fd, "r");
|
||||
f = take_fdopen(&fd, "r");
|
||||
if (!f)
|
||||
return -errno;
|
||||
fd = -1;
|
||||
|
||||
/* c is only needed if we actually load the file (it's referenced from items[] btw, in case you wonder.) */
|
||||
assert(c);
|
||||
|
||||
Reference in New Issue
Block a user