svn commit: samba r16397 - in branches/SAMBA_3_0/source/smbd: .

James Peach jpeach at samba.org
Wed Jun 21 04:38:32 GMT 2006


On Tue, 2006-06-20 at 08:52 -0700, Jeremy Allison wrote:
> On Tue, Jun 20, 2006 at 05:21:24PM +1000, James Peach wrote:
> > On Tue, 2006-06-20 at 02:38 +0000, jra at samba.org wrote:
> > > Author: jra
> > > Date: 2006-06-20 02:38:28 +0000 (Tue, 20 Jun 2006)
> > > New Revision: 16397
> > > 
> > > WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=16397
> > > 
> > > Log:
> > > Fix Klocwork #11767 and drasticly simplify the
> > > logic in smbd/process.c. All interested (Volker,
> > > Jerry, James etc). PLEASE REVIEW THIS CHANGE.
> > > The logic should be identical but *much* easier
> > > to follow and change (and shouldn't confuse Klockwork :-).
> > 
> > You lost the AS_GUEST flag clearing on purpose?
> 
> Yes. If you look at the SMB definition table (function mapper)
> you will see that if AS_USER is set then AS_GUEST is *never*
> set.


Could you add an SMB_ASSERT to that effect?

if (flags) {
	SMB_ASSERT((flags & AS_USER) ? !(flags & AS_GUEST)
                                     : (flags & AS_GUEST) )
}

> This makes that clause impossible to be executed.

Agreed (provided no-one ever adds AS_USER | AS_GUEST to smb_messages).


-- 
James Peach | jpeach at samba.org



More information about the samba-cvs mailing list