Home GnuPG

core: Add a limited version of gpgrt_ftruncate.

Description

core: Add a limited version of gpgrt_ftruncate.

* src/gpg-error.h.in (gpgrt_ftruncate, es_ftruncate): New.
* src/gpg-error.def.in, src/gpg-error.vers: Add gpgrt_ftruncate.
* src/visibility.c (gpgrt_ftruncate): new.
* src/gpgrt-int.h (COOKIE_IOCTL_TRUNCATE): New.
* src/estream.c (func_mem_ioctl): Support new internal IOCTL.
(_gpgrt_ftruncate): New.

Right now the ftruncate works only on memory streams. Can easily be
added to other stream times.

  • Signed-off-by: Werner Koch <wk@gnupg.org>

Details

Provenance
wernerAuthored on Nov 26 2018, 8:06 PM
Parents
rEa5d4a4b32b11: core: New API gpgrt_cmp_version
Branches
Unknown
Tags
Unknown