Samba VFS Module and Crashes
Kevin Wheatley
hxpro at cinesite.co.uk
Fri Jun 28 04:10:02 GMT 2002
William234 at aol.com wrote:
> Is there something better to use then safe_strcat()? Possibly
> safe_sprintf()?
Hi,
couple of suggestions:
You've got 256 chars allocated but your filling it with somewhere near
60 chars of constant text + username + date + time (8) + path, etc,
all it would take is a reasonably long path and your going to run into
problems with truncation.
What's the %F formatter do ? IRIX doesn't have that documented in
strftime()
also should the sizeof()'s be -1 to ensure you don't overrun ?
Also I notice your null terminating your last safe_strcat twice.
I would have thought using strnprintf() would be better overall
anyway.
Kevin
--
| Kevin Wheatley | These are the opinions of |
| No Title No Department | nobody and are not shared |
| Cinesite (Europe) Ltd | by my employers |
More information about the samba-technical
mailing list