diff options
author | Roland Dreier <rolandd@cisco.com> | 2006-04-03 09:31:04 -0700 |
---|---|---|
committer | Roland Dreier <rolandd@cisco.com> | 2006-04-03 09:31:04 -0700 |
commit | ce1823f0323be9f38bbe0df229a5bba025404923 (patch) | |
tree | f3c896b952cf01fb81054f65f2861be0e2d4f437 /drivers/infiniband | |
parent | 227c939b00cf786b5e2e95fc904518206f478421 (diff) | |
download | lwn-ce1823f0323be9f38bbe0df229a5bba025404923.tar.gz lwn-ce1823f0323be9f38bbe0df229a5bba025404923.zip |
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>
Diffstat (limited to 'drivers/infiniband')
-rw-r--r-- | drivers/infiniband/ulp/srp/ib_srp.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/infiniband/ulp/srp/ib_srp.c b/drivers/infiniband/ulp/srp/ib_srp.c index fd8a95a9c5d3..5f2b3f6e4c47 100644 --- a/drivers/infiniband/ulp/srp/ib_srp.c +++ b/drivers/infiniband/ulp/srp/ib_srp.c @@ -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; } |