Fix: report error using fd instead of ret
authorJonathan Rajotte <jonathan.rajotte-julien@efficios.com>
Tue, 25 Jul 2017 14:45:32 +0000 (10:45 -0400)
committerJérémie Galarneau <jeremie.galarneau@efficios.com>
Tue, 1 Aug 2017 21:11:28 +0000 (17:11 -0400)
Signed-off-by: Jonathan Rajotte <jonathan.rajotte-julien@efficios.com>
Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
src/common/utils.c

index 16d2f817ad8a1b21d99228a67e5bba25e0d1f3fa..aa11551c30635fd4e423382092fd1871a2534b17 100644 (file)
@@ -528,7 +528,7 @@ int utils_create_lock_file(const char *filepath)
                S_IRGRP | S_IWGRP);
        if (fd < 0) {
                PERROR("open lock file %s", filepath);
-               ret = -1;
+               fd = -1;
                goto error;
        }
 
This page took 0.025634 seconds and 4 git commands to generate.