aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorNeal Walfield <[email protected]>2003-02-18 20:48:52 +0000
committerNeal Walfield <[email protected]>2003-02-18 20:48:52 +0000
commita234d2e994399e3c8228ee0f840b93516e93cc6f (patch)
tree68cb8a79aa3524bf4f64ce813dd25f711329a7cd /src
parent/ (diff)
downloadlibassuan-a234d2e994399e3c8228ee0f840b93516e93cc6f.tar.gz
libassuan-a234d2e994399e3c8228ee0f840b93516e93cc6f.zip
/
2003-02-18 Neal H. Walfield <[email protected]> * common: New directory. * Makefile.am (SUBDIRS): Add common. * configure.ac: Check for funopen. If not present, check for fopencookie and implement it in terms of that. Otherwise, fail. (AC_CONFIG_FILES): Add common/Makefile. src/ 2003-02-18 Neal H. Walfield <[email protected]> * assuan-handler.c (_IO_cookie_io_functions_t): Remove. (cookie_io_functions_t): Remove. (fopencookie): Remove prototype. (assuan_get_data_fp): Use funopen, not fopencookie. common/ 2003-02-18 Neal H. Walfield <[email protected]> * Makefile.am: New file. * funopen.c: New file. * isascii.c: Imported from newpg. * memrchr.c: Likewise. * putc_unlocked.c: Likewise.
Diffstat (limited to 'src')
-rw-r--r--src/ChangeLog7
-rw-r--r--src/assuan-handler.c31
2 files changed, 11 insertions, 27 deletions
diff --git a/src/ChangeLog b/src/ChangeLog
index 06e331c..688bcf0 100644
--- a/src/ChangeLog
+++ b/src/ChangeLog
@@ -1,5 +1,12 @@
2003-02-18 Neal H. Walfield <[email protected]>
+ * assuan-handler.c (_IO_cookie_io_functions_t): Remove.
+ (cookie_io_functions_t): Remove.
+ (fopencookie): Remove prototype.
+ (assuan_get_data_fp): Use funopen, not fopencookie.
+
+2003-02-18 Neal H. Walfield <[email protected]>
+
* libassuan-config.in: New file.
* Makefile.am (bin_PROGRAMS): New variable.
diff --git a/src/assuan-handler.c b/src/assuan-handler.c
index 532cafa..9d73e0e 100644
--- a/src/assuan-handler.c
+++ b/src/assuan-handler.c
@@ -1,5 +1,5 @@
/* assuan-handler.c - dispatch commands
- * Copyright (C) 2001, 2002 Free Software Foundation, Inc.
+ * Copyright (C) 2001, 2002, 2003 Free Software Foundation, Inc.
*
* This file is part of Assuan.
*
@@ -28,27 +28,6 @@
#define spacep(p) (*(p) == ' ' || *(p) == '\t')
#define digitp(a) ((a) >= '0' && (a) <= '9')
-
-#if !HAVE_FOPENCOOKIE
-/* Provide structure for our dummy replacement function. Usually this
- is defined in ../common/util.h but assuan should be self
- contained. */
-/* Fixme: Remove fopencoookie :-(( */
-typedef struct
-{
- ssize_t (*read)(void*,char*,size_t);
- ssize_t (*write)(void*,const char*,size_t);
- int (*seek)(void*,off_t*,int);
- int (*close)(void*);
-} _IO_cookie_io_functions_t;
-typedef _IO_cookie_io_functions_t cookie_io_functions_t;
-FILE *fopencookie (void *cookie, const char *opentype,
- cookie_io_functions_t funclist);
-#endif /*!HAVE_FOPENCOOKIE*/
-
-
-
-
static int
dummy_handler (ASSUAN_CONTEXT ctx, char *line)
{
@@ -636,12 +615,10 @@ assuan_get_data_fp (ASSUAN_CONTEXT ctx)
if (ctx->outbound.data.fp)
return ctx->outbound.data.fp;
- cookie_fnc.read = NULL;
- cookie_fnc.write = _assuan_cookie_write_data;
- cookie_fnc.seek = NULL;
- cookie_fnc.close = _assuan_cookie_write_flush;
- ctx->outbound.data.fp = fopencookie (ctx, "wb", cookie_fnc);
+ ctx->outbound.data.fp = funopen (ctx, 0,
+ _assuan_cookie_write_data,
+ 0, _assuan_cookie_write_flush);
ctx->outbound.data.error = 0;
return ctx->outbound.data.fp;
}