aboutsummaryrefslogtreecommitdiffstats
path: root/tests/opassuan/t-command.c
diff options
context:
space:
mode:
authorMarcus Brinkmann <[email protected]>2012-02-08 14:26:17 +0000
committerMarcus Brinkmann <[email protected]>2012-02-08 14:26:17 +0000
commitdae3073aaa8b7feb1c844fdaf711f79141b9cc65 (patch)
tree5e298888803b5e9f6ba2656759bb76a6c27c6d5e /tests/opassuan/t-command.c
parentLink the thread test to pthread. (diff)
downloadgpgme-dae3073aaa8b7feb1c844fdaf711f79141b9cc65.tar.gz
gpgme-dae3073aaa8b7feb1c844fdaf711f79141b9cc65.zip
Use gpgme interface for error handling to avoid linking with gpg-error.
* tests/t-data.c, tests/run-export.c, tests/run-keylist.c, tests/run-support.h, tests/run-verify.c, tests/gpg/t-decrypt-verify.c, tests/gpg/t-edit.c, tests/gpg/t-eventloop.c, tests/gpg/t-keylist-sig.c, tests/gpg/t-keylist.c, tests/gpg/t-support.h, tests/gpg/t-trustlist.c, tests/gpg/t-verify.c, tests/gpg/t-wait.c, tests/gpgsm/cms-decrypt.c, tests/gpgsm/cms-keylist.c, tests/gpgsm/t-keylist.c, tests/gpgsm/t-support.h, tests/gpgsm/t-verify.c, tests/opassuan/t-command.c: Use gpgme interface for gpg-error functions.
Diffstat (limited to '')
-rw-r--r--tests/opassuan/t-command.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/tests/opassuan/t-command.c b/tests/opassuan/t-command.c
index aa5f34ce..87f82024 100644
--- a/tests/opassuan/t-command.c
+++ b/tests/opassuan/t-command.c
@@ -34,16 +34,16 @@
if (err) \
{ \
fprintf (stderr, "%s:%d: %s: %s (%d.%d)\n", \
- __FILE__, __LINE__, gpg_strsource (err), \
- gpg_strerror (err), \
- gpg_err_source (err), gpg_err_code (err)); \
+ __FILE__, __LINE__, gpgme_strsource (err), \
+ gpgme_strerror (err), \
+ gpgme_err_source (err), gpgme_err_code (err)); \
exit (1); \
} \
} \
while (0)
-static gpg_error_t
+static gpgme_error_t
data_cb (void *opaque, const void *data, size_t datalen)
{
printf ("DATA_CB: datalen=%d\n", (int)datalen);
@@ -51,12 +51,12 @@ data_cb (void *opaque, const void *data, size_t datalen)
}
-static gpg_error_t
+static gpgme_error_t
inq_cb (void *opaque, const char *name, const char *args,
gpgme_data_t *r_data)
{
gpgme_data_t data;
- gpg_error_t err;
+ gpgme_error_t err;
if (name)
{
@@ -81,14 +81,14 @@ inq_cb (void *opaque, const char *name, const char *args,
/* Uncomment the next lines and send a "SCD LEARN" to test sending
cancel from in inquiry. */
/* if (name && !strcmp (name, "KNOWNCARDP")) */
- /* return gpg_error (GPG_ERR_ASS_CANCELED); */
+ /* return gpgme_error (GPG_ERR_ASS_CANCELED); */
return 0;
}
-static gpg_error_t
+static gpgme_error_t
status_cb (void *opaque, const char *status, const char *args)
{
printf ("STATUS_CB: status=`%s' args=`%s'\n", status, args);