signcrl: Remove useless assignment
authorTobias Brunner <tobias@strongswan.org>
Mon, 17 Sep 2018 14:11:05 +0000 (16:11 +0200)
committerTobias Brunner <tobias@strongswan.org>
Mon, 17 Sep 2018 16:51:41 +0000 (18:51 +0200)
src/pki/commands/signcrl.c

index 50f9396..ca208a5 100644 (file)
@@ -124,7 +124,7 @@ static int sign_crl()
        char *arg, *cacert = NULL, *cakey = NULL, *lastupdate = NULL, *error = NULL;
        char *basecrl = NULL;
        char serial[512], *keyid = NULL;
-       int serial_len = 0;
+       int serial_len;
        crl_reason_t reason = CRL_REASON_UNSPECIFIED;
        time_t thisUpdate, nextUpdate, date = time(NULL);
        time_t lifetime = 15 * 24 * 60 * 60;
@@ -204,7 +204,6 @@ static int sign_crl()
                                }
                                add_revoked(list, chunk_create(serial, serial_len), reason, date);
                                date = time(NULL);
-                               serial_len = 0;
                                reason = CRL_REASON_UNSPECIFIED;
                                continue;
                        case 's':
@@ -222,7 +221,6 @@ static int sign_crl()
                                serial_len = chunk.len;
                                add_revoked(list, chunk_create(serial, serial_len), reason, date);
                                date = time(NULL);
-                               serial_len = 0;
                                reason = CRL_REASON_UNSPECIFIED;
                                continue;
                        }