From: Günther Deschner Date: Sun, 8 Feb 2009 23:06:36 +0000 (+0100) Subject: s3-rpcclient: fix getform command asprintf return code. X-Git-Tag: samba-4.0.0alpha7~416^2~48 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=45f142fe29059accad5ff408e844ad3ae29e3b96;p=thirdparty%2Fsamba.git s3-rpcclient: fix getform command asprintf return code. Guenther --- diff --git a/source3/rpcclient/cmd_spoolss.c b/source3/rpcclient/cmd_spoolss.c index 8003180fdab..a7a7fef6ec8 100644 --- a/source3/rpcclient/cmd_spoolss.c +++ b/source3/rpcclient/cmd_spoolss.c @@ -1827,7 +1827,7 @@ static WERROR cmd_spoolss_getform(struct rpc_pipe_client *cli, TALLOC_CTX *mem_c return WERR_NOMEM; } strupper_m(servername); - if (asprintf(&printername, "%s\\%s", servername, argv[1])) { + if (asprintf(&printername, "%s\\%s", servername, argv[1]) == -1) { SAFE_FREE(servername); return WERR_NOMEM; }