Home GnuPG

On Windows, use gpgme_off_t and gpgme_ssize_t in the API

Description

On Windows, use gpgme_off_t and gpgme_ssize_t in the API

* src/callbacks.cpp (passphrase_callback): Use gpgme_ssize_t.
(data_seek_callback): Don't cast offset to off_t.
* src/data.cpp (Data::Data, Data::read, Data::write, Data::seek): Use
gpgme_off_t and gpgme_ssize_t instead of off_t and ssize_t everywhere.
* src/data.h (Data::Data, Data::read, Data::write, Data::seek): On
Windows, use gpgme_off_t and gpgme_ssize_t in the API.
* src/interfaces/dataprovider.h (DataProvider::read,
DataProvider::write, DataProvider::seek): Ditto.

This aligns the API with the API of the gpgme_data_* functions which
also use gpgme_off_t and gpgme_ssize_t on Windows and which otherwise
use off_t and ssize_t. Internally, we always use the gpgme_* types since
they are aliases of the POSIX types on non-Windows.

Details

Provenance
ikloeckerAuthored on Tue, May 27, 4:06 PM
Parents
rGPGMEPP67abbf811080: Fix wrong definition of operator<<(std::ostream &, const Error &)
Branches
Unknown
Tags
Unknown
References
HEAD -> master