chiark / gitweb /
Always use errno > 0 to help gcc
[elogind.git] / src / libsystemd-bus / sd-bus.c
index 6acc59e82c49401ce486e618401a4afbd1c93b78..08a218b7cccbf7174f16f5b2da789fa1a194ffc3 100644 (file)
@@ -507,7 +507,7 @@ static int parse_exec_address(sd_bus *b, const char **p, char **guid) {
 
                         errno = 0;
                         ul = strtoul(*p + 4, (char**) p, 10);
-                        if (errno != 0 || **p != '=' || ul > 256) {
+                        if (errno > 0 || **p != '=' || ul > 256) {
                                 r = -EINVAL;
                                 goto fail;
                         }