]> git.ipfire.org Git - thirdparty/openssh-portable.git/commit
upstream commit
authorschwarze@openbsd.org <schwarze@openbsd.org>
Mon, 30 May 2016 12:05:56 +0000 (12:05 +0000)
committerDarren Tucker <dtucker@zip.com.au>
Mon, 6 Jun 2016 01:27:38 +0000 (11:27 +1000)
commitac284a355f8065eaef2a16f446f3c44cdd17371d
treede00e4236e35e385771974e7daedec02a4064f0f
parent0e059cdf5fd86297546c63fa8607c24059118832
upstream commit

Fix two rare edge cases: 1. If vasprintf() returns < 0,
 do not access a NULL pointer in snmprintf(), and do not free() the pointer
 returned from vasprintf() because on some systems other than OpenBSD, it
 might be a bogus pointer. 2. If vasprintf() returns == 0, return 0 and ""
 rather than -1 and NULL.

Besides, free(dst) is pointless after failure (not a bug).

One half OK martijn@, the other half OK deraadt@;
committing quickly before people get hurt.

Upstream-ID: b7bcd2e82fc168a8eff94e41f5db336ed986fed0
utf8.c