[PATCH] smbtree_showsharetype.patch

Jeremy Allison jra at samba.org
Fri Feb 13 16:21:14 MST 2009


On Tue, Feb 10, 2009 at 11:49:34AM +0000, Seb James wrote:
> Hi List,
> 
> I have a patch for smbtree.c made against samba 3.3.0 which adds an
> option for the user to include the share type in the list of shares
> which smbtree prints.
> 
> I'd very much welcome feedback from the smbtree maintainer about this
> patch and whether it might make it into the samba source. If it's not
> thought a suitable change, I'd like to know if any code changes would
> alter that.

I like this, and I know that char val[16] is safe for
all the uses you've used it for in this patch, but I'd
still like to see it use asprintf() instead (and check
for malloc fail) and correctly free. I'm trying to move
us away from static buffers on the stack, that way lies
future security issues :-).

Jeremy.


More information about the samba-technical mailing list