lkml.org 
[lkml]   [2022]   [Nov]   [26]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
SubjectRe: [PATCH v2 2/2] RDMA/srp: Fix error return code in srp_parse_options()
From


在 2022/11/26 20:03, Andy Shevchenko 写道:
> On Sat, Nov 26, 2022 at 02:02:14PM +0200, Andy Shevchenko wrote:
>> On Sat, Nov 26, 2022 at 11:35:04AM +0800, Wang Yufen wrote:
>
> ...
>
>>> target->scsi_host->can_queue);
>>
>> The below can't be like this, right?
>>
>>> +out_with_einval:
>>> + ret = -EINVAL;
>>> out:
>>> kfree(options);
>>> return ret;
>
> One option is:
>
> out:
> kfree(options);
> return ret;
>
> out_with_einval:
> ret = -EINVAL;
> goto out;

I got it.
Thanks!

>
>

\
 
 \ /
  Last update: 2022-11-26 14:20    [W:0.065 / U:0.924 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site