Call gpgme_check_version() before using other gpgpe functions.
authorgraham.gower@gmail.com <graham.gower@gmail.com@e8e0d7a0-c8d9-11dd-a880-a1081c7ac358>
Mon, 14 Feb 2011 02:46:33 +0000 (02:46 +0000)
committergraham.gower@gmail.com <graham.gower@gmail.com@e8e0d7a0-c8d9-11dd-a880-a1081c7ac358>
Mon, 14 Feb 2011 02:46:33 +0000 (02:46 +0000)
The function initializes some sub-systems, and for this reason alone
it must be invoked early in your program, before you make use of the
other functions in GPGME.
see http://pyme.sourceforge.net/doc/gpgme/Library-Version-Check.html

Patch from Bernhard Guillon.

git-svn-id: http://opkg.googlecode.com/svn/trunk@602 e8e0d7a0-c8d9-11dd-a880-a1081c7ac358

libopkg/opkg_download.c

index b1f009fa937ee9ce8e439d1dae273528ff5dcd67..16502d1b91634322f736e0f274ab54b8520402da 100644 (file)
@@ -340,6 +340,8 @@ opkg_verify_file (char *text_file, char *sig_file)
     gpgme_signature_t s;
     char *trusted_path = NULL;
 
+    gpgme_check_version (NULL);
+
     err = gpgme_new (&ctx);
 
     if (err)