core: Ensure err is initalized in gpg_encrypt
authorAndre Heinecke <aheinecke@intevation.de>
Wed, 10 Aug 2016 08:27:05 +0000 (10:27 +0200)
committerAndre Heinecke <aheinecke@intevation.de>
Wed, 10 Aug 2016 08:27:05 +0000 (10:27 +0200)
* src/engine-gpg.c (gpg_encrypt): Initialize err.

src/engine-gpg.c

index ae78d9d..4fad977 100644 (file)
@@ -1717,7 +1717,7 @@ gpg_encrypt (void *engine, gpgme_key_t recp[], gpgme_encrypt_flags_t flags,
             gpgme_data_t plain, gpgme_data_t ciph, int use_armor)
 {
   engine_gpg_t gpg = engine;
-  gpgme_error_t err;
+  gpgme_error_t err = 0;
 
   if (recp)
     err = add_arg (gpg, "--encrypt");