Re: [PATCH][SMB3] skip extra NULL byte in filenames

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

 



On 08/23, Steve French wrote:
Any comments on Paulo's recent patch below?

   Since commit:
    cifs: alloc_path_with_tree_prefix: do not append sep. if the path is empty
   alloc_path_with_tree_prefix() function was no longer including the
   trailing separator when @path is empty, although @out_len was still
   assuming a path separator thus adding an extra byte to the final
   filename.

   This has caused mount issues in some Synology servers due to the extra
   NULL byte in filenames when sending SMB2_CREATE requests with
   SMB2_FLAGS_DFS_OPERATIONS set.

   Fix this by checking if @path is not empty and then add extra byte for
   separator.  Also, do not include any trailing NULL bytes in filename
   as MS-SMB2 requires it to be 8-byte aligned and not NULL terminated.

Reviewed-by: Enzo Matsumiya <ematsumiya@xxxxxxx>


Cheers,

Enzo

--
Thanks,

Steve






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

  Powered by Linux