Re: [bug report] ksmbd: add support for read compound

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

 



On Tue, Sep 12, 2023 at 10:03:27PM +0900, Namjae Jeon wrote:
> 2023-09-11 23:31 GMT+09:00, Dan Carpenter <dan.carpenter@xxxxxxxxxx>:
> >     6309         if (is_rdma_channel == true) {
> >     6310                 /* write data to the client using rdma channel */
> >     6311                 remain_bytes = smb2_read_rdma_channel(work, req,
> >     6312
> > aux_payload_buf,
> >     6313                                                       nbytes);
> >     6314                 kvfree(aux_payload_buf);
> >                          ^^^^^^^^^^^^^^^^^^^^^^^
> > freed
> >
> >     6315
> >     6316                 nbytes = 0;
> >
> > I guess probably it doesn't matter that we're passing a freed variable
> > if nbytes is zero.
> >  But could we also just set "aux_payload_buf = NULL"?
> > I am not going to try silence this type of warning in Smatch.
> Yes, It isn't a problem... but will fix it to make smatch happy.
> 

Thanks!

regards,
dan carpenter




[Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux