Home GnuPG
Diffusion GPGME 3cf9aedc92b6

python: Default whence argument for Data() to SEEK_SET.

Description

python: Default whence argument for Data() to SEEK_SET.

* lang/python/gpgme.i: copied signature from gpgme.h and defaulted the
value to SEEK_SET.
* lang/python/tests/t-data.py: Added a test for no second argument

Having to import the os package when wanting to read a Data object is a
slight annoyance. With SWIG, we can define default parameters. This
change defaults the whence argument to SEEK_SET which is how StringIO
and BytesIO behave.

  • Signed-off-by: Tobias Mueller <muelli@cryptobitch.de>

Details

Provenance
4tmuelleAuthored on Aug 22 2017, 5:48 PM
wernerCommitted on Dec 4 2017, 8:10 AM
Parents
rM2205ee2cd922: Register DCO for Tobias Mueller
Branches
Unknown
Tags
Unknown