diff options
Diffstat (limited to 'source3/lib/util.c')
-rw-r--r-- | source3/lib/util.c | 17 |
1 files changed, 16 insertions, 1 deletions
diff --git a/source3/lib/util.c b/source3/lib/util.c index d82dbddb44..63dda489d4 100644 --- a/source3/lib/util.c +++ b/source3/lib/util.c @@ -54,7 +54,7 @@ int trans_num = 0; */ int case_default = CASE_LOWER; -pstring debugf = "/tmp/log.samba"; +pstring debugf = ""; int syslog_level; /* the following control case operations - they are put here so the @@ -271,6 +271,21 @@ va_dcl } /**************************************************************************** + find a suitable temporary directory. The result should be copied immediately + as it may be overwritten by a subsequent call + ****************************************************************************/ +char *tmpdir(void) +{ + char *p; + if ((p = getenv("TMPDIR"))) { + return p; + } + return "/tmp"; +} + + + +/**************************************************************************** determine if a file descriptor is in fact a socket ****************************************************************************/ BOOL is_a_socket(int fd) |