[PATCH] Fix Gluster bug - unable to create file/directory under root of the share due to empty dirpath during get_real_filename()
jra at samba.org
Wed Aug 22 17:03:47 UTC 2018
On Wed, Aug 22, 2018 at 06:58:29PM +0200, Michael Adam wrote:
> On 2018-08-22 at 09:49 -0700, Jeremy Allison wrote:
> > On Wed, Aug 22, 2018 at 06:43:11PM +0200, Michael Adam wrote:
> > > >
> > > > Your gluster-specific fix, whilst not wrong, isn't general enough.
> > >
> > > Hm. You say it's a gluster-specific bug to be fixed.
> > > And you fixed it in one layer above the call to
> > > the gluster specific function. So yours is too
> > > general (I'd say). But mine fixed it at the gluster level
> > Nope, as you pointed out there may be other
> > filesystems that need this issue fixing in
> > the same way.
> Yeah, I know... ;-)
> > > and you say it's not general enough. How can that
> > > be? There's exactly one call between the two places.
> > Fixing it in vfs_glusterfs isn't where it's already
> > done in get_real_filename_full_scan(),
> Oh, great, that kindof convinces me, thanks!
> > so doing it
> > in get_real_filename() which can call get_real_filename_full_scan()
> > makes it general for all VFS filesystems that might need it.
> okay... get_real_filename_full_scan() is *only* called in
> get_real_filename(), so do you want me to provide a patch
> that removes the check from get_real_filename_full_scan()?
> Or do we want to leave it there fore safety, should the
> function be called from another location in the future?
Good catch ! Yeah, I think leave it for safety just
in case it gets externally exposed. Might remove it
as part of the cleanup patch.
> > Your fix is specific to Gluster, not general enough.
> Yeah, I was mainly bitching about the fact that the
> commit message just mentiones gluster. :-)
Sorry, that's where it was discovered so it should
be mentioned IMHO (currently we only know of gluster
users who would come across it, so it gives them
something to search on).
More information about the samba-technical