summaryrefslogtreecommitdiff
path: root/source3/librpc
diff options
context:
space:
mode:
authorJeremy Allison <jra@samba.org>2012-08-08 17:01:00 -0700
committerJeremy Allison <jra@samba.org>2012-08-09 12:08:18 -0700
commitb70f23c2b581c5d455362ab37f4846de9a910055 (patch)
treecf95e8d35a03d1e39d5926d2e03d7046d42cae64 /source3/librpc
parentce21d0804012da27cec72abe896352d7f0e7e1e5 (diff)
downloadsamba-b70f23c2b581c5d455362ab37f4846de9a910055.tar.gz
samba-b70f23c2b581c5d455362ab37f4846de9a910055.tar.bz2
samba-b70f23c2b581c5d455362ab37f4846de9a910055.zip
Correctly check for errors in strlower_m() returns.
Diffstat (limited to 'source3/librpc')
-rw-r--r--source3/librpc/crypto/gse_krb5.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/source3/librpc/crypto/gse_krb5.c b/source3/librpc/crypto/gse_krb5.c
index dbcc520048..43f545ad4c 100644
--- a/source3/librpc/crypto/gse_krb5.c
+++ b/source3/librpc/crypto/gse_krb5.c
@@ -96,7 +96,10 @@ static krb5_error_code get_host_principal(krb5_context krbctx,
return -1;
}
- strlower_m(host_princ_s);
+ if (!strlower_m(host_princ_s)) {
+ SAFE_FREE(host_princ_s);
+ return -1;
+ }
ret = smb_krb5_parse_name(krbctx, host_princ_s, host_princ);
if (ret) {
DEBUG(1, (__location__ ": smb_krb5_parse_name(%s) "