diff options
| author | Werner Koch <[email protected]> | 2013-02-06 16:35:40 +0000 | 
|---|---|---|
| committer | Werner Koch <[email protected]> | 2013-02-06 16:35:40 +0000 | 
| commit | 51fd6d8292cb41d743407e6ac9d86a5ab8e68d8c (patch) | |
| tree | d431a193f5eece63dba5aa6485416e79f67396cb /src/import.c | |
| parent | Improve parsing of the GIT revision number. (diff) | |
| download | gpgme-51fd6d8292cb41d743407e6ac9d86a5ab8e68d8c.tar.gz gpgme-51fd6d8292cb41d743407e6ac9d86a5ab8e68d8c.zip  | |
Use gpg_error_from_syserror instead of directly accessing errno.
--
Also fixed a couple of minor thing; e.g. save the error before calling
cleanup functions.  Do not save the errno if only free is called
in between.
Diffstat (limited to 'src/import.c')
| -rw-r--r-- | src/import.c | 3 | 
1 files changed, 1 insertions, 2 deletions
diff --git a/src/import.c b/src/import.c index d4edaba1..6233a155 100644 --- a/src/import.c +++ b/src/import.c @@ -174,9 +174,8 @@ parse_import (char *args, gpgme_import_status_t *import_status, int problem)    import->fpr = strdup (args);    if (!import->fpr)      { -      int saved_errno = errno;        free (import); -      return gpg_error_from_errno (saved_errno); +      return gpg_error_from_syserror ();      }    *import_status = import;  | 
