svn commit: r309868 - stable/11/usr.sbin/ctld
Xin LI
delphij at FreeBSD.org
Mon Dec 12 02:20:21 UTC 2016
Author: delphij
Date: Mon Dec 12 02:20:20 2016
New Revision: 309868
URL: https://svnweb.freebsd.org/changeset/base/309868
Log:
MFC r309241,309243:
Plug memory leaks.
Modified:
stable/11/usr.sbin/ctld/ctld.c
Directory Properties:
stable/11/ (props changed)
Modified: stable/11/usr.sbin/ctld/ctld.c
==============================================================================
--- stable/11/usr.sbin/ctld/ctld.c Mon Dec 12 02:14:42 2016 (r309867)
+++ stable/11/usr.sbin/ctld/ctld.c Mon Dec 12 02:20:20 2016 (r309868)
@@ -401,6 +401,7 @@ auth_portal_new(struct auth_group *ag, c
return (ap);
error:
+ free(str);
free(ap);
log_warnx("incorrect initiator portal \"%s\"", portal);
return (NULL);
@@ -675,8 +676,10 @@ parse_addr_port(char *arg, const char *d
*/
arg++;
addr = strsep(&arg, "]");
- if (arg == NULL)
+ if (arg == NULL) {
+ free(str);
return (1);
+ }
if (arg[0] == '\0') {
port = def_port;
} else if (arg[0] == ':') {
More information about the svn-src-stable-11
mailing list