Re: [PATCH] RDMA/siw: fix a refcount leak in siw_newlink()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 2023/03/24 21:20, Bernard Metzler wrote:
>> @@ -522,6 +522,8 @@ static int siw_newlink(const char *basedev_name, struct
>> net_device *netdev)
>>  		rv = siw_device_register(sdev, basedev_name);
>>  		if (rv)
>>  			ib_dealloc_device(&sdev->base_dev);
>> +	} else {
>> +		ib_device_put(base_dev);
> 
> base_dev is always NULL here, so nothing to put,
> right?

Oops, indeed. Then, there is a leak somewhere else.

> 
> 
>>  	}
>>  	return rv;
>>  }
>> --
>> 2.18.4




[Index of Archives]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Photo]     [Yosemite News]     [Yosemite Photos]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux