]> git.ipfire.org Git - thirdparty/gnutls.git/commitdiff
tests: corrected detection of 64-bit systems in softhsm.h
authorNikos Mavrogiannopoulos <nmav@redhat.com>
Mon, 5 Sep 2016 07:41:30 +0000 (09:41 +0200)
committerNikos Mavrogiannopoulos <nmav@redhat.com>
Mon, 5 Sep 2016 09:36:34 +0000 (11:36 +0200)
tests/pkcs11/softhsm.h

index bd94bd8526bfb3962b59bd257f27c87e41857fb6..725d29efdb0c676c2b0a4e21b8f0cb981ecfc293 100644 (file)
@@ -50,13 +50,13 @@ inline static const char *softhsm_lib(void)
 {
        const char *lib;
 
-       if (sizeof(int) == 8 && access(LIB1, R_OK) == 0) {
+       if (sizeof(long) == 8 && access(LIB1, R_OK) == 0) {
                lib = LIB1;
        } else if (access(LIB2, R_OK) == 0) {
                lib = LIB2;
        } else if (access(LIB3, R_OK) == 0) {
                lib = LIB3;
-       } else if (sizeof(int) == 8 && access(LIB4, R_OK) == 0) {
+       } else if (sizeof(long) == 8 && access(LIB4, R_OK) == 0) {
                lib = LIB4;
        } else {
                fprintf(stderr, "cannot find softhsm module\n");