mirror of
git://git.gnupg.org/gnupg.git
synced 2025-01-26 15:37:03 +01:00
* hkp.c (parse_hkp_index): Be more robust with keyservers returning very
unparseable responses. * exec.c (exec_read): Catch and display an error when the remote process exits unnaturally (i.e. segfault) so the user knows what happened. Also fix exec_write stub which has a different number of arguments now.
This commit is contained in:
parent
d8524b8461
commit
e1f88c5d3f
@ -1,3 +1,13 @@
|
|||||||
|
2002-06-05 David Shaw <dshaw@jabberwocky.com>
|
||||||
|
|
||||||
|
* hkp.c (parse_hkp_index): Be more robust with keyservers
|
||||||
|
returning very unparseable responses.
|
||||||
|
|
||||||
|
* exec.c (exec_read): Catch and display an error when the remote
|
||||||
|
process exits unnaturally (i.e. segfault) so the user knows what
|
||||||
|
happened. Also fix exec_write stub which has a different number
|
||||||
|
of arguments now.
|
||||||
|
|
||||||
2002-06-05 Timo Schulz <ts@winpt.org>
|
2002-06-05 Timo Schulz <ts@winpt.org>
|
||||||
|
|
||||||
* encode.c (encode_simple): Ignore the new mode for RFC1991.
|
* encode.c (encode_simple): Ignore the new mode for RFC1991.
|
||||||
|
18
g10/exec.c
18
g10/exec.c
@ -43,7 +43,7 @@
|
|||||||
|
|
||||||
#ifdef NO_EXEC
|
#ifdef NO_EXEC
|
||||||
int exec_write(struct exec_info **info,const char *program,
|
int exec_write(struct exec_info **info,const char *program,
|
||||||
const char *args_in,int writeonly,int binary)
|
const char *args_in,const char *name,int writeonly,int binary)
|
||||||
{
|
{
|
||||||
log_error(_("no remote program execution supported\n"));
|
log_error(_("no remote program execution supported\n"));
|
||||||
return G10ERR_GENERAL;
|
return G10ERR_GENERAL;
|
||||||
@ -473,14 +473,20 @@ int exec_read(struct exec_info *info)
|
|||||||
info->progreturn=127;
|
info->progreturn=127;
|
||||||
goto fail;
|
goto fail;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#if defined(WIFEXITED) && defined(WEXITSTATUS)
|
||||||
|
if(WIFEXITED(info->progreturn))
|
||||||
|
info->progreturn=WEXITSTATUS(info->progreturn);
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
#ifdef WEXITSTATUS
|
log_error(_("unnatural exit of external program\n"));
|
||||||
info->progreturn=WEXITSTATUS(info->progreturn);
|
info->progreturn=127;
|
||||||
#else
|
goto fail;
|
||||||
info->progreturn/=256;
|
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
|
#else
|
||||||
|
/* If we don't have the macros, do the best we can. */
|
||||||
|
info->progreturn/=256;
|
||||||
|
#endif
|
||||||
|
|
||||||
/* 127 is the magic value returned from system() to indicate
|
/* 127 is the magic value returned from system() to indicate
|
||||||
that the shell could not be executed, or from /bin/sh to
|
that the shell could not be executed, or from /bin/sh to
|
||||||
|
@ -280,7 +280,8 @@ parse_hkp_index(IOBUF buffer,char *line)
|
|||||||
{
|
{
|
||||||
char intstr[11];
|
char intstr[11];
|
||||||
|
|
||||||
write_quoted(buffer,key,':');
|
if(key)
|
||||||
|
write_quoted(buffer,key,':');
|
||||||
iobuf_writestr(buffer,":");
|
iobuf_writestr(buffer,":");
|
||||||
write_quoted(buffer,uid,':');
|
write_quoted(buffer,uid,':');
|
||||||
iobuf_writestr(buffer,":");
|
iobuf_writestr(buffer,":");
|
||||||
|
Loading…
x
Reference in New Issue
Block a user