1
0
Fork 0
mirror of git://git.gnupg.org/gnupg.git synced 2025-07-02 22:46:30 +02:00

Workaround for a mingw runtime bug.

This commit is contained in:
Werner Koch 2008-09-04 10:35:41 +00:00
parent 5a8bf0bec6
commit d30fdae24b
3 changed files with 12 additions and 2 deletions

View file

@ -1,3 +1,7 @@
2008-09-04 Werner Koch <wk@g10code.com>
* certdump.c (gpgsm_format_keydesc): Work around a mingw32 bug.
2008-09-03 Werner Koch <wk@g10code.com>
* sign.c (MY_GCRY_MD_SHA224): New, so that we don't need libgcrypt

View file

@ -979,7 +979,13 @@ gpgsm_format_keydesc (ksba_cert_t cert)
buffer = p = xtrymalloc (strlen (name) * 3 + 1);
for (s=name; *s; s++)
{
if (*s < ' ' || *s == '+')
/* We also escape the quote character to work around a bug in
the mingw32 runtime which does not correcty handle command
line quoting. We correctly double the quote mark when
calling a program (i.e. gpg-protec-tool), but the pre-main
code does not notice the double quote as an escaped
quote. */
if (*s < ' ' || *s == '+' || *s == '\"')
{
sprintf (p, "%%%02X", *(unsigned char *)s);
p += 3;