[PATCH] Fix compiler warning

Anoop C S anoopcs at redhat.com
Tue Oct 20 07:14:57 UTC 2015


On Fri, 2015-10-16 at 10:33 -0700, Jeremy Allison wrote:
> On Fri, Oct 16, 2015 at 01:38:38PM +0200, Michael Adam wrote:
> > On 2015-10-16 at 16:58 +0530, Anoop C S wrote:
> > > Hi,
> > > 
> > > Please see the attached patch which fixes a compiler warning from
> > > sysquotas_nfs.c
> > 
> > To me, this looks good. I also already discussed this with Anoop.
> > All definitions of the enum I can find start with 1.
> > But I don't know all the history. This code originally comes from
> > source3/smbd/quotas.c, added in 2001:
> > f439f72ceec665dbd1eae367eb5d7302d8a3338d
> > Has the definition been different back then? ...
> > 
> > So I tentatively give my review.
> > (Barring explanation why we need the 0 case... ;-)
> 
> No, it's good. If you look at the zero case it's
> merely being used as a different error case, which is already
> correctly handled in default:
> 
> I'll push. Thanks Anoop !
> 
> > If this is OK, then we need the corresponding patch to
> > smbd/quotas.c, Anoop.
> 
> Yes please !

I have attached the similar patch for smbd/quotas.c. Do we need to
separate out different switch cases for quota status here with
corresponding DEBUG messages?

Thanks & Regards
--Anoop C S.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-smbd-quotas-Remove-invalid-quota-status-switch-case.patch
Type: text/x-patch
Size: 1456 bytes
Desc: not available
URL: <http://lists.samba.org/pipermail/samba-technical/attachments/20151020/141ed5f1/0001-smbd-quotas-Remove-invalid-quota-status-switch-case.bin>


More information about the samba-technical mailing list