]> err.no Git - yubikey-personalization/commitdiff
use memcmp instead of strcmp
authorKlas Lindfors <klas@yubico.com>
Mon, 3 Mar 2014 10:12:07 +0000 (11:12 +0100)
committerKlas Lindfors <klas@yubico.com>
Mon, 3 Mar 2014 10:20:19 +0000 (11:20 +0100)
tests/test_args_to_config.c

index 65bbf4c22aa41967df4d5788ab0bb871068bfdf0..00392dfb426b4483a19d2820b8e60af90f922abe 100644 (file)
@@ -345,7 +345,7 @@ static void _test_non_config_args(void)
        assert(rc == 1);
        i = strcmp(infname, "in"); assert(i == 0);
        i = strcmp(outfname, "out"); assert(i == 0);
-       i = strcmp(access_code, "123456"); assert(i == 0);
+       i = memcmp(access_code, "123456", 6); assert(i == 0);
        assert(autocommit == true);
        assert(verbose == true);