]> git.kernelconcepts.de Git - karo-tx-linux.git/blobdiff - drivers/s390/net/qeth.h
[PATCH] s390: qeth driver fixes
[karo-tx-linux.git] / drivers / s390 / net / qeth.h
index 4df0fcd7b10b18a092aaeba16d6e1f80b120b9e4..65e2b1bc08a5a77f38b88a67ccca8c2f9474dc72 100644 (file)
@@ -1099,7 +1099,7 @@ qeth_string_to_ipaddr4(const char *buf, __u8 *addr)
 
        rc = sscanf(buf, "%d.%d.%d.%d%n", 
                    &in[0], &in[1], &in[2], &in[3], &count);
-       if (rc != 4  || count
+       if (rc != 4  || count<=0)
                return -EINVAL;
        for (count = 0; count < 4; count++) {
                if (in[count] > 255)