diff options
author | Volker Lendecke <vl@samba.org> | 2008-04-19 22:05:13 +0200 |
---|---|---|
committer | Volker Lendecke <vl@samba.org> | 2008-04-20 00:13:39 +0200 |
commit | 4c857010e7113d99028cf8d7fac5e5b95c400fb3 (patch) | |
tree | 7ce4469fcb1032d5e1c572067fecdd5a8f0fb627 /source3 | |
parent | 2a2188591b5ed922d09dc723adcf10f8b8f5e5a0 (diff) | |
download | samba-4c857010e7113d99028cf8d7fac5e5b95c400fb3.tar.gz samba-4c857010e7113d99028cf8d7fac5e5b95c400fb3.tar.bz2 samba-4c857010e7113d99028cf8d7fac5e5b95c400fb3.zip |
Fix two "ignoring asprintf result" warnings
(This used to be commit 1d261e78b38e8080ca7122037d33c8ef913a4558)
Diffstat (limited to 'source3')
-rw-r--r-- | source3/libads/ldap_printer.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/source3/libads/ldap_printer.c b/source3/libads/ldap_printer.c index e2396ce4cf..440f979781 100644 --- a/source3/libads/ldap_printer.c +++ b/source3/libads/ldap_printer.c @@ -288,9 +288,8 @@ WERROR get_remote_printer_publishing_data(struct rpc_pipe_client *cli, uint32 i; POLICY_HND pol; - asprintf(&servername, "\\\\%s", cli->desthost); - asprintf(&printername, "%s\\%s", servername, printer); - if (!servername || !printername) { + if ((asprintf(&servername, "\\\\%s", cli->desthost) == -1) + || (asprintf(&printername, "%s\\%s", servername, printer) == -1)) { DEBUG(3, ("Insufficient memory\n")); return WERR_NOMEM; } |