Blob Blame Raw
--- pygpgme-0.1/src/pygpgme-context.c~  2006-02-14 05:05:15.000000000 +0100
+++ pygpgme/src/pygpgme-context.c   2008-11-06 15:01:58.000000000 +0100
@@ -356,6 +356,22 @@
     { NULL, (getter)0, (setter)0 }
 };
 
+static PyObject *
+pygpgme_context_set_engine_info(PyGpgmeContext *self, PyObject *args)
+{
+    int protocol;
+    const char *file_name, *home_dir;
+
+    if (!PyArg_ParseTuple(args, "izz", &protocol, &file_name, &home_dir))
+        return NULL;
+
+    if (pygpgme_check_error(gpgme_ctx_set_engine_info(self->ctx, protocol,
+                                                      file_name, home_dir)))
+        return NULL;
+
+    Py_RETURN_NONE;
+}
+
 /* XXX: set_locale */
 static PyObject *
 pygpgme_context_set_locale(PyGpgmeContext *self, PyObject *args)
@@ -1136,6 +1152,7 @@
 // pygpgme_context_trustlist
 
 static PyMethodDef pygpgme_context_methods[] = {
+    { "set_engine_info", (PyCFunction)pygpgme_context_set_engine_info, METH_VARARGS },
     { "set_locale", (PyCFunction)pygpgme_context_set_locale, METH_VARARGS },
     { "get_key", (PyCFunction)pygpgme_context_get_key, METH_VARARGS },
     { "encrypt", (PyCFunction)pygpgme_context_encrypt, METH_VARARGS },