1
0
mirror of https://github.com/samba-team/samba.git synced 2024-12-31 17:18:04 +03:00
Commit Graph

11 Commits

Author SHA1 Message Date
Andrew Bartlett
e68684aa65 Fix 2 off-by-one bugs in the use of malloc()ed strings and safe_strcpy().
safe_strcpy() isn't particularly safe (this has been noted before) as it does
not take the size of the buffer, but instead the size of the buffer *minus 1*

The locking.c fix was causing segfaults on machines running with
--enable-developer, and was tracked down thanks to the fact that vance's build
farm machine runs with such an option, and smbtorture's DIR1 test hits this
bug very well.

(The --enable-developer code writes to the last byte of the string, to check
for incorrect use of safe_strcpy()).

Andrew Bartlett
(This used to be commit e908fd164d)
2003-02-24 01:13:31 +00:00
Andrew Bartlett
7e110f782a More signed/unsigned fixes (yes, I run with funny compiler options) and
make x_fwrite() match fwrite() in returning a size_t.

Andrew Bartlett
(This used to be commit 2943c69578)
2003-02-22 12:22:06 +00:00
Tim Potter
cd68afe312 Removed version number from file header.
Changed "SMB/Netbios" to "SMB/CIFS" in file header.
(This used to be commit 6a58c9bd06)
2002-01-30 06:08:46 +00:00
Tim Potter
dc1fc3ee8e Removed 'extern int DEBUGLEVEL' as it is now in the smb.h header.
(This used to be commit 2d0922b0ea)
2001-10-02 04:29:50 +00:00
Andrew Tridgell
666f8a09b2 fixed the really awful performance problem with the stat cache when it
ran out of primes and used a power of two hash modulus. It ended up
sticking all the entries in just a few buckets. Yuck!
(This used to be commit fdc9952391)
2001-09-25 06:39:41 +00:00
Andrew Bartlett
2309cd7f64 Fix (I hope) compile on HP-UX. Found by the build farm.
(This used to be commit fd5c67d35a)
2001-09-19 04:16:35 +00:00
Simo Sorce
484a7c0341 move to SAFE_FREE()
(This used to be commit 60e907b7e8)
2001-09-17 02:19:44 +00:00
Jeremy Allison
495aa4c28a string_hash() should be static. hash_clear() should be void.
Jeremy.
(This used to be commit e8ab89fbc0)
2001-05-12 20:15:39 +00:00
Jeremy Allison
4248374c84 Made re-init of stat cache explicit rather than being hidden.
Jeremy.
(This used to be commit b0c40236bb)
2000-10-04 22:37:33 +00:00
Jeremy Allison
eab8f3c940 Fix from Elrond for hash table corruption. Should fix stat cache bug (I
sincerely hope :-). Thanks elrond !
Jeremy.
(This used to be commit 0d59e8c6bf)
2000-06-09 18:54:41 +00:00
Jeremy Allison
ace4006c9f Added hash-based stat cache code from Ying Chen.
Jeremy.
(This used to be commit b62a1bd632)
2000-01-26 21:25:35 +00:00