GNUPG-1-9-BRANCH gnupg/scd (ChangeLog app-common.h app-openpgp.c)
cvs user wk
cvs at cvs.gnupg.org
Fri Oct 22 11:38:30 CEST 2004
Date: Friday, October 22, 2004 @ 11:41:56
Author: wk
Path: /cvs/gnupg/gnupg/scd
Tag: GNUPG-1-9-BRANCH
Modified: ChangeLog app-common.h app-openpgp.c
* app-openpgp.c (do_sign): Replace asprintf by direct allocation.
This avoids problems with missing vasprintf implementations in
gnupg 1.4.
* app-common.h (app_openpgp_storekey: Add prototype.
---------------+
ChangeLog | 8 ++++++++
app-common.h | 9 ++++++++-
app-openpgp.c | 11 ++++++++---
3 files changed, 24 insertions(+), 4 deletions(-)
Index: gnupg/scd/ChangeLog
diff -u gnupg/scd/ChangeLog:1.25.2.56 gnupg/scd/ChangeLog:1.25.2.57
--- gnupg/scd/ChangeLog:1.25.2.56 Wed Oct 20 10:54:45 2004
+++ gnupg/scd/ChangeLog Fri Oct 22 11:41:56 2004
@@ -1,3 +1,11 @@
+2004-10-21 Werner Koch <wk at g10code.com>
+
+ * app-openpgp.c (do_sign): Replace asprintf by direct allocation.
+ This avoids problems with missing vasprintf implementations in
+ gnupg 1.4.
+
+ * app-common.h (app_openpgp_storekey: Add prototype.
+
2004-10-20 Werner Koch <wk at g10code.com>
* sc-investigate: Removed.
Index: gnupg/scd/app-common.h
diff -u gnupg/scd/app-common.h:1.5.2.10 gnupg/scd/app-common.h:1.5.2.11
--- gnupg/scd/app-common.h:1.5.2.10 Thu Oct 14 11:12:36 2004
+++ gnupg/scd/app-common.h Fri Oct 22 11:41:56 2004
@@ -17,7 +17,7 @@
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
*
- * $Id: app-common.h,v 1.5.2.10 2004/10/14 09:12:36 werner Exp $
+ * $Id: app-common.h,v 1.5.2.11 2004/10/22 09:41:56 wk Exp $
*/
#ifndef GNUPG_SCD_APP_COMMON_H
@@ -88,6 +88,13 @@
#if GNUPG_MAJOR_VERSION == 1
int app_select_openpgp (app_t app);
int app_get_serial_and_stamp (app_t app, char **serial, time_t *stamp);
+int app_openpgp_storekey (app_t app, int keyno,
+ unsigned char *template, size_t template_len,
+ time_t created_at,
+ const unsigned char *m, size_t mlen,
+ const unsigned char *e, size_t elen,
+ int (*pincb)(void*, const char *, char **),
+ void *pincb_arg);
#else
/*-- app-help.c --*/
gpg_error_t app_help_get_keygrip_string (ksba_cert_t cert, char *hexkeygrip);
Index: gnupg/scd/app-openpgp.c
diff -u gnupg/scd/app-openpgp.c:1.9.2.21 gnupg/scd/app-openpgp.c:1.9.2.22
--- gnupg/scd/app-openpgp.c:1.9.2.21 Thu Oct 14 15:22:03 2004
+++ gnupg/scd/app-openpgp.c Fri Oct 22 11:41:56 2004
@@ -17,7 +17,7 @@
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
*
- * $Id: app-openpgp.c,v 1.9.2.21 2004/10/14 13:22:03 werner Exp $
+ * $Id: app-openpgp.c,v 1.9.2.22 2004/10/22 09:41:56 wk Exp $
*/
#include <config.h>
@@ -824,7 +824,7 @@
if (strlen (pinvalue) < 6)
{
- log_error (_("prassphrase (CHV%d) is too short;"
+ log_error (_("passphrase (CHV%d) is too short;"
" minimum length is %d\n"), 3, 6);
xfree (pinvalue);
return gpg_error (GPG_ERR_BAD_PIN);
@@ -1298,10 +1298,15 @@
{
char *prompt;
- if (asprintf (&prompt, _("PIN [sigs done: %lu]"), sigcount) < 0)
+#define PROMPTSTRING _("PIN [sigs done: %lu]")
+
+ prompt = malloc (strlen (PROMPTSTRING) + 50);
+ if (!prompt)
return gpg_error_from_errno (errno);
+ sprintf (prompt, PROMPTSTRING, sigcount);
rc = pincb (pincb_arg, prompt, &pinvalue);
free (prompt);
+#undef PROMPTSTRING
}
if (rc)
{
More information about the Gnupg-commits
mailing list