mirror of git://anongit.mindrot.org/openssh.git
- (dtucker) [openbsd-compat/getrrsetbyname.c] Prevent getrrsetbyname from
failing with NOMEMORY if no sigs are returned and malloc(0) returns NULL. From Martin.Kraemer at Fujitsu-Siemens.com; ok djm@
This commit is contained in:
parent
11bdc01cfe
commit
f00e51d1f2
|
@ -1,3 +1,8 @@
|
|||
20040829
|
||||
- (dtucker) [openbsd-compat/getrrsetbyname.c] Prevent getrrsetbyname from
|
||||
failing with NOMEMORY if no sigs are returned and malloc(0) returns NULL.
|
||||
From Martin.Kraemer at Fujitsu-Siemens.com; ok djm@
|
||||
|
||||
20040828
|
||||
- (dtucker) [openbsd-compat/mktemp.c] Remove superfluous Cygwin #ifdef; from
|
||||
vinschen at redhat.com.
|
||||
|
@ -1664,4 +1669,4 @@
|
|||
- (djm) Trim deprecated options from INSTALL. Mention UsePAM
|
||||
- (djm) Fix quote handling in sftp; Patch from admorten AT umich.edu
|
||||
|
||||
$Id: ChangeLog,v 1.3521 2004/08/28 06:17:35 dtucker Exp $
|
||||
$Id: ChangeLog,v 1.3522 2004/08/29 06:12:29 dtucker Exp $
|
||||
|
|
|
@ -277,7 +277,7 @@ getrrsetbyname(const char *hostname, unsigned int rdclass,
|
|||
|
||||
/* allocate memory for signatures */
|
||||
rrset->rri_sigs = calloc(rrset->rri_nsigs, sizeof(struct rdatainfo));
|
||||
if (rrset->rri_sigs == NULL) {
|
||||
if (rrset->rri_nsigs > 0 && rrset->rri_sigs == NULL) {
|
||||
result = ERRSET_NOMEMORY;
|
||||
goto fail;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue