tree-wide: avoid uninitialized warning on _cleanup_ variables
With some versions of the compiler, the _cleanup_ attr makes it think the variable might be freed/closed when uninitialized, even though it cannot happen. The added cost is small enough to be worth the benefit, and optimized builds will help reduce it even further.
This commit is contained in:
@@ -33,7 +33,7 @@ int find_key_file(
|
||||
}
|
||||
|
||||
STRV_FOREACH(i, search_path) {
|
||||
_cleanup_free_ char *joined;
|
||||
_cleanup_free_ char *joined = NULL;
|
||||
|
||||
joined = path_join(*i, key_file);
|
||||
if (!joined)
|
||||
|
||||
Reference in New Issue
Block a user