36 |
#include "wptContext.h" /* for passphrase_s */ |
#include "wptContext.h" /* for passphrase_s */ |
37 |
#include "wptDlgs.h" |
#include "wptDlgs.h" |
38 |
|
|
39 |
|
|
40 |
/* Sign the clipboard contents with the key @keyid and wrap |
/* Sign the clipboard contents with the key @keyid and wrap |
41 |
text lines to @wraplen (0 disable line wrapping). |
text lines to @wraplen (0 disable line wrapping). |
42 |
Return value: 0 on success. */ |
Return value: 0 on success. */ |
108 |
|
|
109 |
set_gpg_passphrase_cb (&pwd, ctx, GPG_CMD_SIGN, dlg, _("Signing")); |
set_gpg_passphrase_cb (&pwd, ctx, GPG_CMD_SIGN, dlg, _("Signing")); |
110 |
err = gpg_clip_sign (ctx, signer, n ); |
err = gpg_clip_sign (ctx, signer, n ); |
111 |
memset (pwd.pwd, 0, sizeof pwd.pwd); |
wipememory (pwd.pwd, sizeof (pwd.pwd)); |
112 |
if (gpgme_err_code (err) == GPG_ERR_BAD_PASSPHRASE) |
if (gpgme_err_code (err) == GPG_ERR_BAD_PASSPHRASE) |
113 |
agent_del_cache (pwd.keyid); |
agent_del_cache (pwd.keyid); |
114 |
if (err) |
if (err) |