diff options
| author | Justus Winter <[email protected]> | 2016-07-11 14:34:15 +0000 | 
|---|---|---|
| committer | Justus Winter <[email protected]> | 2016-07-11 15:50:58 +0000 | 
| commit | 98cba522c906115efcba1f8cc0bec7e5edb51ecd (patch) | |
| tree | f7c9a12d934907e3b3eab109f745dfb0f9d9fe77 /lang/python/helpers.c | |
| parent | python: Make result wrapping backwards compatible. (diff) | |
| download | gpgme-98cba522c906115efcba1f8cc0bec7e5edb51ecd.tar.gz gpgme-98cba522c906115efcba1f8cc0bec7e5edb51ecd.zip | |
python: Do not depend on access to internal data structures.
* lang/python/gpgme.i (gpgme_data_t): Rework so that it works without
access to the definition of 'struct gpgme_data'.
* lang/python/helpers.c (object_to_gpgme_data_t): Add assertion.
Signed-off-by: Justus Winter <[email protected]>
Diffstat (limited to 'lang/python/helpers.c')
| -rw-r--r-- | lang/python/helpers.c | 1 | 
1 files changed, 1 insertions, 0 deletions
| diff --git a/lang/python/helpers.c b/lang/python/helpers.c index 43a55d08..d6cbb883 100644 --- a/lang/python/helpers.c +++ b/lang/python/helpers.c @@ -254,6 +254,7 @@ object_to_gpgme_data_t(PyObject *input, int argnum, gpgme_data_t *wrapper,        if (data != input)          Py_DECREF(data); +      assert (view->obj);        assert (view->ndim == 1);        assert (view->shape == NULL);        assert (view->strides == NULL); | 
