Check return value from asprintf instead of string != NULL since it

undefined behavior on Linux. From Björn Sandell


git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@16220 ec53bebd-3082-4978-b11e-865c3cabbd6b
This commit is contained in:
Love Hörnquist Åstrand
2005-10-22 15:07:48 +00:00
parent 4232beb6e4
commit 4863ea9553
3 changed files with 29 additions and 12 deletions

View File

@@ -325,6 +325,10 @@ send_krb5_auth(int s,
do_encrypt ? "-x " : "",
cmd,
remote_user);
if (cksum_data.length == -1) {
warnx ("%s: failed to allocate command", hostname);
return 1;
}
ap_opts = 0;