summaryrefslogtreecommitdiffstats
path: root/source/lib/debug.c
Commit message (Collapse)AuthorAgeFilesLines
* Converted the code in smbd/dir.c to use bitmaps instead of a staticJeremy Allison1999-01-061-2/+2
| | | | | | | | array for directory handles. This tidied up the code a *lot*. Plus it means I've fixed the bug in PR#10058, which was due to an NT app that wanted to simultaneously open >256 directory handles. Jeremy.
* Makefile.in: script install fix from Tim Rice.Jeremy Allison1998-12-141-2/+2
| | | | | lib/debug.c: File size check from Jasper. Jeremy.
* Changed (most) open()/fopen()/creat()/mmap() calls to use sys_XXX() instead.Jeremy Allison1998-11-171-4/+4
| | | | | | Needed as in the 64 bit file spec new open types are needed on many OS's to be able to seek past 32bits. Jeremy.
* Changes to test in configure if capabilities are enabled on a system.Jeremy Allison1998-09-281-0/+4
| | | | | | | | | | Changes to get Samba to compile cleanly with the IRIX compiler with the options : -fullwarn -woff 1209,1174 (the -woff options are to turn off warnings about unused function parameters and controlling loop expressions being constants). Split prototype generation as we hit a limit in IRIX nawk. Removed "." code in smbd/filename.c (yet again :-). Jeremy.
* configure configure.in: Added checks for statvfs64. Last bit of 64 bit ↵Jeremy Allison1998-09-171-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | widening (I hope :-). include/config.h.in: Added #undef STAT_STATVFS64. include/includes.h: Added SMB_STRUCT_STATVFS type, Changed SMB_BIG_INTEGER to SMB_BIG_UINT and SMB_BIG_INT types. include/smb.h: Added flag defines from CIFS spec. lib/debug.c: Fixed one more mode_t issue. lib/system.c: Added sys_statvfs wrapper. lib/util.c: Changed trim_string to use size_t. param/loadparm.c: Moved "blocking locks" into locking section. Alphabetised locking options. Question - shuld we do this for all options ? passdb/ldap.c: Changed SMB_BIG_INTEGER to SMB_BIG_UINT. passdb/nispass.c: Changed SMB_BIG_INTEGER to SMB_BIG_UINT. passdb/smbpass.c: Changed SMB_BIG_INTEGER to SMB_BIG_UINT. smbd/dfree.c: Changed to use 64 bit types if available. Moved to use unsigned types. smbd/dosmode.c: Fixed one more mode_t issue. smbd/negprot.c: Changed literals to be FLAG_ #defines. smbd/nttrans.c: Removed dead code. smbd/open.c: Changed disk_free call. smbd/process.c: Changed literals to be FLAG_ #defines. smbd/reply.c: Changed disk_free call. smbd/trans2.c: Fixed but in SMB_QUERY_FS_VOLUME_INFO call. Was using UNICODE - should use ascii. tests/summary.c: Added STAT_STATVFS64 check. Jeremy.
* Ok - this is the 64 bit widening check in. It changes the configureJeremy Allison1998-09-031-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | to check for stat64 and friends, and then changes much of Samba to use the data type SMB_OFF_T for file size information. stat/fstat/lstat/lseek/ftruncate have now become sys_stat etc. to hide the 64 bit calls if needed. Note that this still does not expose 64 bit functionality to the client, as the changes to the reply_xxx smb's are not yet done. This code change should make these changes possible. Still to do before full 64 bit-ness to the client: fcntl lock code. statfs code widening of dev_t and ino_t (now possible due to SMB_DEV_T and SMB_OFF_T types being in place). Let me know if wierd things happen after this check-in and I'll fix them :-). Jeremy.
* More abstraction of file system data types, to move to a 64Jeremy Allison1998-09-011-1/+1
| | | | | | | | | | | | | | | | | | | | | bit file interface for the NT SMB's. Created a new define, SMB_STRUCT_STAT that currently is defined to be struct stat - this wil change to a user defined type containing 64 bit info when the correct wrappers are written for 64 bit stat(), fstat() and lstat() calls. Also changed all sys_xxxx() calls that were previously just wrappers to the same call prefixed by a dos_to_unix() call into dos_xxxx() calls. This makes it explicit when a pathname translation is being done, and when it is not. Now, all sys_xxx() calls are meant to be wrappers to mask OS differences, and not silently converting filenames on the fly. Jeremy.
* don't put two spaces at the start of lines if logging to stdoutAndrew Tridgell1998-08-301-1/+3
| | | | or not timestamping.
* Just tweaking.Christopher R. Hertel1998-08-211-2/+20
| | | | | | | | | | | If the output line is longer than the format buffer could manage, I was simply ignoring the additional output (that is, *not* copying it to the format buffer--thus avoiding a buffer overrun). Instead, I now output the current content followed by " +>\n", and then reset the format buffer. I have never seen a debug line that exceeds the size of a pstring, but I might as well handle the situation...just in case. Chris -)-----
* configure: Changes for extra headers.Jeremy Allison1998-08-151-4/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | configure.in: Source for header changes. client/clitar.c: Fixed isXXX macros & debugs for gcc pedantic compile. include/config.h.in: Added MEMSET, BZERO, MEMORY, RPCSVC_YPCLNT, STRINGS headers. include/includes.h: Headers for the above. include/smb.h: Made SIGNAL_CAST POSIX by default void (*)(int). lib/access.c: Fixed isXXX macros & debugs for gcc pedantic compile. lib/charset.c: Fixed isXXX macros & debugs for gcc pedantic compile. lib/debug.c: Fixed signal functs. lib/kanji.c: Fixed isXXX macros & debugs for gcc pedantic compile. lib/smbrun.c: Fixed isXXX macros & debugs for gcc pedantic compile. lib/util.c: Fixed isXXX macros & debugs for gcc pedantic compile. libsmb/namequery.c: Fixed isXXX macros & debugs for gcc pedantic compile. locking/shmem.c: Fixed isXXX macros & debugs for gcc pedantic compile. locking/shmem_sysv.c: Fixed error messages in sysV stuff. nmbd/asyncdns.c: Fixed signal functs. nmbd/nmbd.c: Fixed isXXX macros & debugs for gcc pedantic compile. passdb/passdb.c: Fixed isXXX macros & debugs for gcc pedantic compile. passdb/smbpassfile.c: Fixed isXXX macros & debugs for gcc pedantic compile. smbd/chgpasswd.c: Fixed isXXX macros & debugs for gcc pedantic compile. smbd/ipc.c: Fixed isXXX macros & debugs for gcc pedantic compile. smbd/nttrans.c: Fixed fsp code path. smbd/password.c: fixed HAVE_YP_GET_DEFAULT_DOMAIN problem. smbd/printing.c: Fixed isXXX macros & debugs for gcc pedantic compile. smbd/reply.c: Fixed isXXX macros & debugs for gcc pedantic compile. smbd/server.c: Fixed isXXX macros & debugs for gcc pedantic compile. smbd/trans2.c: Fixed core dump bug. smbd/uid.c: Fixed isXXX macros & debugs for gcc pedantic compile. Jeremy.
* I've added a dbgflush() function to debug.c. Calling this will cause theChristopher R. Hertel1998-08-121-5/+31
| | | | | | | | | debug format buffer to be written out (and reset). fflush() is also called to force the issue. I replaced the call to fflush() in client.c with a call to dbgflush(), which seems to have fixed the problem that Andrew was working on (i.e., that the prompt was not displayed when using smbclient). Chris -)-----
* Cleaned up some lint warnings (functions with return values that wereChristopher R. Hertel1998-08-111-12/+13
| | | | ignored).
* I've added a test for lp_loaded() so that timestamps *will* be outputChristopher R. Hertel1998-08-111-4/+9
| | | | | | | before the config file has been loaded. Otherwise the default is no timestamp. Chris -)-----
* fixed a nasty bug in debug.cAndrew Tridgell1998-08-111-1/+1
| | | | | | | | | | | | | | Debug1() was being called like this: Debug1( format_bufr ); but if format_bufr contains any %s or other % arguments (such as when processing a smb.conf file containing % macros) then smbd dies a horrible death. The quick fix is to use: Debug1( "%s", format_bufr);
* First implementation of ChangeNotify - this version only checksJeremy Allison1998-08-031-2/+3
| | | | | | | | | | | | | | | | | | | for changes in the directory modify timestamps. A better version will look at the requested client flags, and create a hash that represents the current state of the directory, and check against this instead. debug.c: Added lp_timestamp_logs() function. loadparm.c: Added "change notify timeout" in seconds (default 60) - this is the scan rate for a directory. Added ""timestamp logs" boolean - default True. Turns off log timestamps (so I can read them :-). nttrans.c: ChangeNotify implementation. server.c: ChangeNotify implementation. shmem_sysv.c: Added exits on shmem errors (without them smbd can core dump if some calls fail). smb.h: Added ChangeNotify flags for future use. util.c: Tidied up typedef. Jeremy.
* This is the remaining set of changes needed to replace the changes lostChristopher R. Hertel1998-08-031-11/+7
| | | | | | | | when Andrew and I were both working with util.c. I really don't know how I lost the autoconfigure changes (honest, I *did* run frequent updates). Chris -)-----
* I have fixed some of the autoconfigure problems. I'm studying the diffsChristopher R. Hertel1998-08-031-9/+13
| | | | | | | for the rest. I've found that only debug.h seems to be out of sync (i.e., util.c itself appears to be okay). Chris -)-----
* Debugging functions are now in their own module.Christopher R. Hertel1998-07-311-0/+533
Chris -)-----