mirror of
https://github.com/PowerShell/openssh-portable.git
synced 2025-07-28 08:14:24 +02:00
- (dtucker) [openbsd-compat/bsd-misc.c] Bug #1108: fix broken strdup().
Reported by olavi at ipunplugged.com and antoine.brodin at laposte.net via FreeBSD.
This commit is contained in:
parent
42308a4374
commit
d32e293c04
@ -1,3 +1,8 @@
|
|||||||
|
20051102
|
||||||
|
- (dtucker) [openbsd-compat/bsd-misc.c] Bug #1108: fix broken strdup().
|
||||||
|
Reported by olavi at ipunplugged.com and antoine.brodin at laposte.net
|
||||||
|
via FreeBSD.
|
||||||
|
|
||||||
20051030
|
20051030
|
||||||
- (djm) [contrib/suse/openssh.spec contrib/suse/rc.
|
- (djm) [contrib/suse/openssh.spec contrib/suse/rc.
|
||||||
sshd contrib/suse/sysconfig.ssh] Bug #1106: Updated SuSE spec and init
|
sshd contrib/suse/sysconfig.ssh] Bug #1106: Updated SuSE spec and init
|
||||||
@ -3125,4 +3130,4 @@
|
|||||||
- (djm) Trim deprecated options from INSTALL. Mention UsePAM
|
- (djm) Trim deprecated options from INSTALL. Mention UsePAM
|
||||||
- (djm) Fix quote handling in sftp; Patch from admorten AT umich.edu
|
- (djm) Fix quote handling in sftp; Patch from admorten AT umich.edu
|
||||||
|
|
||||||
$Id: ChangeLog,v 1.3925 2005/10/30 04:31:55 dtucker Exp $
|
$Id: ChangeLog,v 1.3926 2005/11/01 22:07:31 dtucker Exp $
|
||||||
|
@ -18,7 +18,7 @@
|
|||||||
#include "includes.h"
|
#include "includes.h"
|
||||||
#include "xmalloc.h"
|
#include "xmalloc.h"
|
||||||
|
|
||||||
RCSID("$Id: bsd-misc.c,v 1.27 2005/05/27 11:13:41 dtucker Exp $");
|
RCSID("$Id: bsd-misc.c,v 1.28 2005/11/01 22:07:31 dtucker Exp $");
|
||||||
|
|
||||||
#ifndef HAVE___PROGNAME
|
#ifndef HAVE___PROGNAME
|
||||||
char *__progname;
|
char *__progname;
|
||||||
@ -223,10 +223,7 @@ strdup(const char *str)
|
|||||||
len = strlen(str) + 1;
|
len = strlen(str) + 1;
|
||||||
cp = malloc(len);
|
cp = malloc(len);
|
||||||
if (cp != NULL)
|
if (cp != NULL)
|
||||||
if (strlcpy(cp, str, len) != len) {
|
return(memcpy(cp, str, len));
|
||||||
free(cp);
|
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
return cp;
|
|
||||||
}
|
|
||||||
#endif
|
#endif
|
||||||
|
Loading…
x
Reference in New Issue
Block a user