vBulletin Search Engine Optimization
| |||||||
| Register | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| ||||
| On Friday 24 March 2006 04:15, Otto Moerbeek wrote: > Hi, > > This is a revised version of the diff Paul Thorn > <pthorn-obsd@styx2002.no-ip.org> send some time ago. It's a mix of > Paul's diff, FreeBSD code and my own: > > - plug a huge leak that occurs if telldir() is called, but no > corresponding seekdir(). Samba is suffering from that. > - Use a data structure local to DIR to store the telldir data. FreeBSD > uses a linked list, I chose to use an array, which avoids allocating > lots of small chunks, the index becomes implicit as well, so we can > drop a field from the struct. > - Make sure that loc = telldir(); .... seekdir(loc); telldir() returns loc, > as POSIX requires. This is an area that can be improved, since it now > scans the array. > > Note that one documented behaviour is changed. POSIX does not require > it, and most other Unix-like system do not give that guarantee. > > Please review and test, especially on setup that uses telldir and > seekdir. AFAIK, no program in base does that, but at least samba > does. > > -Otto From the little testing I have done, this works. However, my users have never had problems in the 2+ years I've had an OpenBSD samba box. But this hasn't introduced any problems. I plan on testing it much more this weekend/next week. --STeve Andre' |
| Thread Tools | |
| Display Modes | |
|
|