]> granicus.if.org Git - p11-kit/commitdiff
p11-kit: Fix redundant check for 'signature' is always 'true'
authorPankaj <pankaj.s01@samsung.com>
Wed, 4 Nov 2015 05:03:00 +0000 (05:03 +0000)
committerStef Walter <stefw@redhat.com>
Mon, 23 Nov 2015 11:41:37 +0000 (12:41 +0100)
https://bugs.freedesktop.org/show_bug.cgi?id=92807

common/mock.c

index ab223f82c8bfe7c11bd87da1021d02fb974a9e8f..1b0aea791d21f3936ecd40d01b0abb1789055085 100644 (file)
@@ -2978,7 +2978,7 @@ mock_C_VerifyFinal (CK_SESSION_HANDLE session,
        len = snprintf (buffer, sizeof (buffer), "%lu", sess->hash_count);
        length = sess->n_sign_prefix + len;
 
-       if (!signature || signature_len != length)
+       if (signature_len != length)
                return CKR_SIGNATURE_LEN_RANGE;
 
        if (memcmp (signature, sess->sign_prefix, sess->n_sign_prefix) != 0 ||