mirror of
git://git.gnupg.org/gnupg.git
synced 2025-07-02 22:46:30 +02:00
common/iobuf.h: Remove iobuf_open_fd_or_name.
* common/iobuf.h (iobuf_open_fd_or_name): Remove prototype. Replace use with either iobuf_open or iobuf_fdopen_nc, as appropriate. * common/iobuf.c (iobuf_open): Remove function. -- Signed-off-by: Neal H. Walfield <neal@g10code.com>.
This commit is contained in:
parent
6d49a2b669
commit
8402815d8e
4 changed files with 6 additions and 22 deletions
|
@ -510,14 +510,17 @@ encrypt_crypt (ctrl_t ctrl, int filefd, const char *filename,
|
|||
/* Prepare iobufs. */
|
||||
#ifdef HAVE_W32_SYSTEM
|
||||
if (filefd == -1)
|
||||
inp = iobuf_open_fd_or_name (GNUPG_INVALID_FD, filename, "rb");
|
||||
inp = iobuf_open (filename);
|
||||
else
|
||||
{
|
||||
inp = NULL;
|
||||
gpg_err_set_errno (ENOSYS);
|
||||
}
|
||||
#else
|
||||
inp = iobuf_open_fd_or_name (filefd, filename, "rb");
|
||||
if (filefd == GNUPG_INVALID_FD)
|
||||
inp = iobuf_open (filename);
|
||||
else
|
||||
inp = iobuf_fdopen_nc (FD2INT(filefd), "rb");
|
||||
#endif
|
||||
if (inp)
|
||||
iobuf_ioctl (inp, IOBUF_IOCTL_NO_CACHE, 1, NULL);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue