]> git.ipfire.org Git - thirdparty/systemd.git/blobdiff - src/import/export.c
tree-wide: use -EBADF for fd initialization
[thirdparty/systemd.git] / src / import / export.c
index 690e19445335e2f20445849d7dd5dee7d540fe38..84609cbe124da43863676423bdf19ac80e1960d2 100644 (file)
@@ -63,7 +63,7 @@ static int export_tar(int argc, char *argv[], void *userdata) {
         _cleanup_(sd_event_unrefp) sd_event *event = NULL;
         _cleanup_(image_unrefp) Image *image = NULL;
         const char *path = NULL, *local = NULL;
-        _cleanup_close_ int open_fd = -1;
+        _cleanup_close_ int open_fd = -EBADF;
         int r, fd;
 
         if (hostname_is_valid(argv[1], 0)) {
@@ -139,7 +139,7 @@ static int export_raw(int argc, char *argv[], void *userdata) {
         _cleanup_(sd_event_unrefp) sd_event *event = NULL;
         _cleanup_(image_unrefp) Image *image = NULL;
         const char *path = NULL, *local = NULL;
-        _cleanup_close_ int open_fd = -1;
+        _cleanup_close_ int open_fd = -EBADF;
         int r, fd;
 
         if (hostname_is_valid(argv[1], 0)) {