diff options
author | Werner Koch <[email protected]> | 2010-07-16 13:19:45 +0000 |
---|---|---|
committer | Werner Koch <[email protected]> | 2010-07-16 13:19:45 +0000 |
commit | 8b8925a2bdbb12dd537dde20a27cdb1416c2f1ae (patch) | |
tree | 366acb6bb52e61242bb39682ddddb76615c3ba34 /common/estream.c | |
parent | Make it build on W32 again. (diff) | |
download | gnupg-8b8925a2bdbb12dd537dde20a27cdb1416c2f1ae.tar.gz gnupg-8b8925a2bdbb12dd537dde20a27cdb1416c2f1ae.zip |
Some work on porting dirmngr (unfinished)
Ported gpgtar to W32.
Diffstat (limited to 'common/estream.c')
-rw-r--r-- | common/estream.c | 16 |
1 files changed, 4 insertions, 12 deletions
diff --git a/common/estream.c b/common/estream.c index bf7955d06..3ab68b5ff 100644 --- a/common/estream.c +++ b/common/estream.c @@ -994,7 +994,7 @@ es_func_fp_seek (void *cookie, off_t *offset, int whence) return 0; } -/* Destroy function for fd objects. */ +/* Destroy function for FILE* objects. */ static int es_func_fp_destroy (void *cookie) { @@ -1076,14 +1076,6 @@ es_func_file_create (void **cookie, int *filedes, return err; } -static es_cookie_io_functions_t estream_functions_file = - { - es_func_fd_read, - es_func_fd_write, - es_func_fd_seek, - es_func_fd_destroy - }; - static int es_convert_mode (const char *mode, unsigned int *modeflags) @@ -2197,7 +2189,7 @@ es_fopen (const char *ES__RESTRICT path, const char *ES__RESTRICT mode) goto out; create_called = 1; - err = es_create (&stream, cookie, fd, estream_functions_file, modeflags, 0); + err = es_create (&stream, cookie, fd, estream_functions_fd, modeflags, 0); if (err) goto out; @@ -2207,7 +2199,7 @@ es_fopen (const char *ES__RESTRICT path, const char *ES__RESTRICT mode) out: if (err && create_called) - (*estream_functions_file.func_close) (cookie); + (*estream_functions_fd.func_close) (cookie); return stream; } @@ -2519,7 +2511,7 @@ es_freopen (const char *ES__RESTRICT path, const char *ES__RESTRICT mode, goto leave; create_called = 1; - es_initialize (stream, cookie, fd, estream_functions_file, modeflags); + es_initialize (stream, cookie, fd, estream_functions_fd, modeflags); leave: |