winbindd (3.0alpha17) memory leak?

Dan Coppock danno at stbernard.com
Thu Mar 21 12:48:05 GMT 2002


FYI, for anyone looking at this, I believe I've identified the problem.  In
lib/talloc.c, in function talloc_vasprintf, the call to vsnprintf...

	len = vsnprintf(NULL, 0, fmt, ap);

...is attempting to get the number of byte that *would have* been printed to
the target string.  The current FreeBSD underlying implementation of
vsnprintf/vfprintf doesn't play nicely, leaving a 1k work buffer un-freed.
According to the cvs log for vsnprintf.c, the FreeBSD developers are aware
of this.

The fix for my purposes is to pass vsnprintf a real buffer and length, and
all seems fine.



More information about the samba-technical mailing list