1
0
Fork 0

IB/srp: Fix memory leak in options parsing

Fix memory leak if parsing destination GID fails.

Coverity bug 1042

Signed-off-by: Roland Dreier <rolandd@cisco.com>
hifive-unleashed-5.1
Roland Dreier 2006-04-03 09:31:04 -07:00
parent 227c939b00
commit ce1823f032
1 changed files with 1 additions and 0 deletions

View File

@ -1434,6 +1434,7 @@ static int srp_parse_options(const char *buf, struct srp_target_port *target)
p = match_strdup(args);
if (strlen(p) != 32) {
printk(KERN_WARNING PFX "bad dest GID parameter '%s'\n", p);
kfree(p);
goto out;
}