From 749325d6c10fd6a8d8fafa3c9c25b6822eaf0dc5 Mon Sep 17 00:00:00 2001 From: Marcus Brinkmann Date: Thu, 6 May 2010 13:39:55 +0000 Subject: 2010-05-06 Marcus Brinkmann * configure.ac: Require libgpg-error 1.8. src/ 2010-05-06 Marcus Brinkmann * sign.c, data-user.c, conversion.c, debug.c, verify.c, data.c, decrypt.c, delete.c, assuan-support.c, import.c, engine-gpgsm.c, data-mem.c, op-support.c, w32-io.c, w32-util.c, data-compat.c: Use gpg_error_from_syserror instead gpg_error_from_errno, and use gpg_err_set_errno to set error number. * setenv.c: Include and define __set_errno to use gpg_err_set_errno. * gpgme-tool.c (ARGP_ERR_UNKNOWN): Define to EDEADLOCK (which is mapped in Windows CE) instead of E2BIG (which is not). (gt_import_keys): Initialize err. --- src/import.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/import.c') diff --git a/src/import.c b/src/import.c index ffab9559..ff5f9b32 100644 --- a/src/import.c +++ b/src/import.c @@ -121,10 +121,10 @@ parse_import (char *args, gpgme_import_status_t *import_status, int problem) import = malloc (sizeof (*import)); if (!import) - return gpg_error_from_errno (errno); + return gpg_error_from_syserror (); import->next = NULL; - errno = 0; + gpg_err_set_errno (0); nr = strtol (args, &tail, 0); if (errno || args == tail || *tail != ' ') { @@ -189,7 +189,7 @@ parse_import_res (char *args, gpgme_import_result_t result) { char *tail; - errno = 0; + gpg_err_set_errno (0); #define PARSE_NEXT(x) \ (x) = strtol (args, &tail, 0); \ -- cgit v1.2.3