2005-03-24 Marcus Brinkmann <marcus@g10code.de>
* configure.ac (AH_BOTTOM): Removed. gpgme/ 2005-03-24 Marcus Brinkmann <marcus@g10code.de> * data.h (EOPNOTSUPP) [_WIN32]: Remove definition. * data.c (EOPNOTSUPP) [HAVE_W32_SYSTEM]: Remove definition. (gpgme_data_read, gpgme_data_write, gpgme_data_seek): Return ENOSYS instead EOPNOTSUPP. * data-compat.c (EOPNOTSUPP) [HAVE_W32_SYSTEM]: Remove definition. (gpgme_error_to_errno): Map GPG_ERR_NOT_SUPPORTED to ENOSYS.
This commit is contained in:
parent
259c65d94f
commit
719d27dfce
@ -1,3 +1,7 @@
|
||||
2005-03-24 Marcus Brinkmann <marcus@g10code.de>
|
||||
|
||||
* configure.ac (AH_BOTTOM): Removed.
|
||||
|
||||
2005-03-09 Werner Koch <wk@g10code.com>
|
||||
|
||||
* acinclude.m4 (GNUPG_CHECK_VA_COPY): Assume no when cross-compiling.
|
||||
|
11
configure.ac
11
configure.ac
@ -68,17 +68,6 @@ AH_VERBATIM([_REENTRANT],
|
||||
# define _REENTRANT 1
|
||||
#endif])
|
||||
|
||||
AH_BOTTOM([
|
||||
/* Some environments miss the definition for EOPNOTSUPP. We provide
|
||||
the error code here and test where neded whether it should be
|
||||
defined. Can't do the test here due to the order of includes. */
|
||||
#ifdef HAVE_W32_SYSTEM
|
||||
#define VALUE_FOR_EOPNOTSUPP 95
|
||||
#endif /*!HAVE_W32_SYSTEM*/
|
||||
|
||||
])
|
||||
|
||||
|
||||
AC_PROG_CC
|
||||
|
||||
|
||||
|
@ -1,3 +1,13 @@
|
||||
2005-03-24 Marcus Brinkmann <marcus@g10code.de>
|
||||
|
||||
* data.h (EOPNOTSUPP) [_WIN32]: Remove definition.
|
||||
* data.c (EOPNOTSUPP) [HAVE_W32_SYSTEM]: Remove definition.
|
||||
(gpgme_data_read, gpgme_data_write, gpgme_data_seek): Return
|
||||
ENOSYS instead EOPNOTSUPP.
|
||||
* data-compat.c (EOPNOTSUPP) [HAVE_W32_SYSTEM]: Remove definition.
|
||||
(gpgme_error_to_errno): Map GPG_ERR_NOT_SUPPORTED
|
||||
to ENOSYS.
|
||||
|
||||
2005-03-24 Marcus Brinkmann <marcus@g10code.de>
|
||||
|
||||
* io.h: Rename to ...
|
||||
|
@ -30,11 +30,6 @@
|
||||
#include "data.h"
|
||||
#include "util.h"
|
||||
|
||||
#if defined(HAVE_W32_SYSTEM) && !defined(EOPNOTSUPP)
|
||||
#define EOPNOTSUPP VALUE_FOR_EOPNOTSUPP
|
||||
#endif
|
||||
|
||||
|
||||
|
||||
/* Create a new data buffer filled with LENGTH bytes starting from
|
||||
OFFSET within the file FNAME or stream STREAM (exactly one must be
|
||||
@ -145,7 +140,7 @@ gpgme_error_to_errno (gpgme_error_t err)
|
||||
errno = EINVAL;
|
||||
return -1;
|
||||
case GPG_ERR_NOT_SUPPORTED:
|
||||
errno = EOPNOTSUPP;
|
||||
errno = ENOSYS;
|
||||
return -1;
|
||||
default:
|
||||
/* FIXME: Yeah, well. */
|
||||
|
11
gpgme/data.c
11
gpgme/data.c
@ -33,11 +33,6 @@
|
||||
#include "ops.h"
|
||||
#include "priv-io.h"
|
||||
|
||||
#if defined(HAVE_W32_SYSTEM) && !defined(EOPNOTSUPP)
|
||||
#define EOPNOTSUPP VALUE_FOR_EOPNOTSUPP
|
||||
#endif
|
||||
|
||||
|
||||
|
||||
gpgme_error_t
|
||||
_gpgme_data_new (gpgme_data_t *r_dh, struct _gpgme_data_cbs *cbs)
|
||||
@ -80,7 +75,7 @@ gpgme_data_read (gpgme_data_t dh, void *buffer, size_t size)
|
||||
}
|
||||
if (!dh->cbs->read)
|
||||
{
|
||||
errno = EOPNOTSUPP;
|
||||
errno = ENOSYS;
|
||||
return -1;
|
||||
}
|
||||
return (*dh->cbs->read) (dh, buffer, size);
|
||||
@ -100,7 +95,7 @@ gpgme_data_write (gpgme_data_t dh, const void *buffer, size_t size)
|
||||
}
|
||||
if (!dh->cbs->write)
|
||||
{
|
||||
errno = EOPNOTSUPP;
|
||||
errno = ENOSYS;
|
||||
return -1;
|
||||
}
|
||||
return (*dh->cbs->write) (dh, buffer, size);
|
||||
@ -120,7 +115,7 @@ gpgme_data_seek (gpgme_data_t dh, off_t offset, int whence)
|
||||
}
|
||||
if (!dh->cbs->seek)
|
||||
{
|
||||
errno = EOPNOTSUPP;
|
||||
errno = ENOSYS;
|
||||
return -1;
|
||||
}
|
||||
|
||||
|
@ -30,10 +30,6 @@
|
||||
|
||||
#include "gpgme.h"
|
||||
|
||||
#ifdef _WIN32
|
||||
# define EOPNOTSUPP 95
|
||||
#endif
|
||||
|
||||
|
||||
/* Read up to SIZE bytes into buffer BUFFER from the data object with
|
||||
the handle DH. Return the number of characters read, 0 on EOF and
|
||||
|
Loading…
Reference in New Issue
Block a user