]> git.ipfire.org Git - thirdparty/HylaFAX.git/commitdiff
Add snprintf and vsnprintf to port functions, add a check for vsnprintf
authorRobert Colquhoun <rjc@trump.net.au>
Wed, 20 Sep 2000 03:55:38 +0000 (03:55 +0000)
committerRobert Colquhoun <rjc@trump.net.au>
Wed, 20 Sep 2000 03:55:38 +0000 (03:55 +0000)
protoype.

Add comment to yesterdays faxsetup.linux changes.

configure
etc/faxsetup.linux

index 76a2a6b913b139a015001f8b82aba02142460dfa..17a69c46bc74c8f88dabb3b0aa9ce7d885e98461 100755 (executable)
--- a/configure
+++ b/configure
@@ -2575,6 +2575,10 @@ BuildPortDotH()
     CheckStdio pclose 'extern int pclose(FILE*);'
     CheckStdio fdopen 'extern FILE* fdopen(int, const char*);'
     CheckStdio snprintf 'extern int snprintf(char*, size_t, const char*,...);'
+    CheckForFuncDecl vsnprintf stdio.h || {
+       echo '#include <stdarg.h>'
+       AddFuncDecl vsnprintf 'extern void vsnprintf(char*, size_t, const char*, va_list);'
+    }
     CheckForDefine fileno stdio.h || {
        CheckStdio fileno 'extern int fileno(FILE*);'
     }
@@ -2899,9 +2903,11 @@ FUNCS="
     setegid
     seteuid
     setvbuf
+    snprintf
     strcasecmp
     strtod
     strtoul
+    vsnprintf
     writev
 "
 
index 1de4092a315482157943dd2b18038d82353af2cb..bac7712909ec67b591d700bcbbfced7f33e89300 100644 (file)
 
 addPasswd()
 {
+    # We're probably creating a user with the same uid as another,
+    # so we need to use 'useradd -o' if available.  Also, some
+    # useradds copy a number of "dot" files when creating the home
+    # directory, so if available, '-M' prevents that, and if it is
+    # an invalid option, then simply not using '-m' will usually 
+    # do the trick.  We have to watch the exit status of this script,
+    # so, the last command run should have somthing to do with the valid
+    # creation of the "fax" user.
+
     if [ -z "`useradd 2>&1 | grep -- -o`" ]; then
         # useradd does *not* support the -o option
         useradd -c 'Facsimile Agent' -d $4 -s /bin/false $1;