OSSP CVS Repository

ossp - Check-in [324]
Not logged in
[Honeypot]  [Browse]  [Home]  [Login]  [Reports
[Search]  [Ticket]  [Timeline
  [Patchset]  [Tagging/Branching

Check-in Number: 324
Date: 2001-Jan-19 15:56:33 (local)
2001-Jan-19 14:56:33 (UTC)
User:rse
Branch:
Comment: Get rid of all complaints from GCC 2.97 (except for two things which I do not want to change on my own)
Tickets:
Inspections:
Files:
ossp-pkg/petidomo/acl.y      1.8 -> 1.9     5 inserted, 5 deleted
ossp-pkg/petidomo/address-db.c      1.2 -> 1.3     2 inserted, 2 deleted
ossp-pkg/petidomo/approve.c      1.3 -> 1.4     7 inserted, 4 deleted
ossp-pkg/petidomo/config.c      1.18 -> 1.19     4 inserted, 4 deleted
ossp-pkg/petidomo/filter.c      1.4 -> 1.5     14 inserted, 13 deleted
ossp-pkg/petidomo/hermes.c      1.13 -> 1.14     2 inserted, 4 deleted
ossp-pkg/petidomo/index.c      1.7 -> 1.8     3 inserted, 2 deleted
ossp-pkg/petidomo/io.c      1.3 -> 1.4     9 inserted, 8 deleted
ossp-pkg/petidomo/libargv/argv.c      1.2 -> 1.3     4 inserted, 4 deleted
ossp-pkg/petidomo/libconfigfile/config.c      1.3 -> 1.4     8 inserted, 8 deleted
ossp-pkg/petidomo/librfc822/address.y      1.3 -> 1.4     3 inserted, 2 deleted
ossp-pkg/petidomo/librfc822/decomment.c      1.3 -> 1.4     3 inserted, 2 deleted
ossp-pkg/petidomo/mailer.c      1.5 -> 1.6     8 inserted, 6 deleted
ossp-pkg/petidomo/members.c      1.8 -> 1.9     2 inserted, 1 deleted
ossp-pkg/petidomo/password.c      1.4 -> 1.5     2 inserted, 1 deleted
ossp-pkg/petidomo/queue_command.c      1.5 -> 1.6     4 inserted, 2 deleted
ossp-pkg/petidomo/queue_posting.c      1.5 -> 1.6     4 inserted, 2 deleted
ossp-pkg/petidomo/subscribe.c      1.18 -> 1.19     4 inserted, 2 deleted
ossp-pkg/petidomo/unsubscribe.c      1.17 -> 1.18     4 inserted, 2 deleted

ossp-pkg/petidomo/acl.y 1.8 -> 1.9

--- acl.y        2001/01/18 20:30:50     1.8
+++ acl.y        2001/01/19 14:56:33     1.9
@@ -1,6 +1,6 @@
 /*
    $Source: /v/ossp/cvs/ossp-pkg/petidomo/acl.y,v $
-   $Revision: 1.8 $
+   $Revision: 1.9 $
 
    Copyright (C) 2000 by CyberSolutions GmbH, Germany.
 
@@ -158,7 +158,7 @@
 
     fh = popen(filter, "w");
     if (fh == NULL) {
-        syslog(LOG_ERR, "Failed to open ACL-filter \"%s\": %m", filter);
+        syslog(LOG_ERR, "Failed to open ACL-filter \"%s\": %s", filter, strerror(errno));
         return -1;
     }
     fprintf(fh, "%s\n", g_MailStruct->Header);
@@ -263,7 +263,7 @@
               /* no master acl file */
               goto check_local_acl_file;
           default:
-              syslog(LOG_ERR, "Couldn't open \"%s\" acl file.: %m", MasterConfig->acl_file);
+              syslog(LOG_ERR, "Couldn't open \"%s\" acl file: %s", MasterConfig->acl_file,  strerror(errno));
               return -1;
         }
     }
@@ -307,7 +307,7 @@
               /* no list acl file */
               goto finished;
           default:
-              syslog(LOG_ERR, "Couldn't open acl file \"%s\": %m", ListConfig->acl_file);
+              syslog(LOG_ERR, "Couldn't open acl file \"%s\": %s", ListConfig->acl_file,  strerror(errno));
               return -1;
         }
     }
@@ -316,7 +316,7 @@
     fclose(yyin);
     yyin = NULL;
     if (rc != 0) {
-        syslog(LOG_ERR, "Parsing \"~petidomo/etc/acl\" file returned with an error.");
+        syslog(LOG_ERR, "Parsing \"%s\" file returned with an error.", ListConfig->acl_file);
         return -1;
     }
 


ossp-pkg/petidomo/address-db.c 1.2 -> 1.3

--- address-db.c 2001/01/18 20:30:50     1.2
+++ address-db.c 2001/01/19 14:56:33     1.3
@@ -1,6 +1,6 @@
 /*
    $Source: /v/ossp/cvs/ossp-pkg/petidomo/address-db.c,v $
-   $Revision: 1.2 $
+   $Revision: 1.3 $
 
    Copyright (C) 2000 by Peter Simons <simons@computer.org>
 
@@ -69,7 +69,7 @@
     fh = fopen(file, "a");
     if (fh == NULL)
         {
-        syslog(LOG_ERR, "Failed to open file \"%s\" for writing: %m", file);
+        syslog(LOG_ERR, "Failed to open file \"%s\" for writing: %s", file, strerror(errno));
         return -1;
         }
     fprintf(fh, "%s\n", address);


ossp-pkg/petidomo/approve.c 1.3 -> 1.4

--- approve.c    2001/01/18 20:30:50     1.3
+++ approve.c    2001/01/19 14:56:33     1.4
@@ -1,6 +1,6 @@
 /*
    $Source: /v/ossp/cvs/ossp-pkg/petidomo/approve.c,v $
-   $Revision: 1.3 $
+   $Revision: 1.4 $
 
    Copyright (C) 2000 by Peter Simons <simons@computer.org>.
 
@@ -17,11 +17,14 @@
    General Public License for more details.
 */
 
-#include "petidomo.h"
 #include <sys/types.h>
 #include <sys/stat.h>
 #include <unistd.h>
 #include <regex.h>
+#include <string.h>
+#include <errno.h>
+
+#include "petidomo.h"
 
 int approve_main(char* mail)
     {
@@ -33,7 +36,7 @@
 
     if (chdir(MasterConfig->ack_queue_dir) == -1)
         {
-        syslog(LOG_ERR, "Can't change directory to \"%s\": %m", MasterConfig->ack_queue_dir);
+        syslog(LOG_ERR, "Can't change directory to \"%s\": %s", MasterConfig->ack_queue_dir, strerror(errno));
         exit(1);
         }
 
@@ -73,7 +76,7 @@
             sprintf(cmd, "/bin/sh %s && /bin/rm -f %s", buffer, buffer);
             if (((signed char)system(cmd)) == -1)
                 {
-                syslog(LOG_ERR, "system() failed: %m", MasterConfig->ack_queue_dir);
+                syslog(LOG_ERR, "system() failed for \"%s\": %s", buffer, strerror(errno));
                 exit(1);
                 }
             }


ossp-pkg/petidomo/config.c 1.18 -> 1.19

--- config.c     2001/01/19 13:12:46     1.18
+++ config.c     2001/01/19 14:56:33     1.19
@@ -1,6 +1,6 @@
 /*
    $Source: /v/ossp/cvs/ossp-pkg/petidomo/Attic/config.c,v $
-   $Revision: 1.18 $
+   $Revision: 1.19 $
 
    Copyright (C) 2000 by CyberSolutions GmbH, Germany.
 
@@ -154,7 +154,7 @@
     int                       rc;
     char *                    buffer;
     struct stat               sb;
-    char*                     list_dir;
+    char*                     this_list_dir;
 
     /* Format description of our global config file. */
 
@@ -211,7 +211,7 @@
     /* No? Then read the config file. */
 
     buffer = text_easy_sprintf("%s/%s/config", MasterConfig->list_dir, listname);
-    list_dir = text_easy_sprintf("%s/%s", MasterConfig->list_dir, listname);
+    this_list_dir = text_easy_sprintf("%s/%s", MasterConfig->list_dir, listname);
     if (stat(buffer, &sb) != 0)
         {
         free(buffer);
@@ -293,7 +293,7 @@
     ListConfig->posting_password = posting_password;
     ListConfig->postingfilter = postingfilter;
 
-    ListConfig->list_dir      = list_dir;
+    ListConfig->list_dir      = this_list_dir;
 
 #define EXPAND(dst, src)                  \
     if (src == NULL || src[0] == '/')     \


ossp-pkg/petidomo/filter.c 1.4 -> 1.5

--- filter.c     2001/01/18 20:30:50     1.4
+++ filter.c     2001/01/19 14:56:33     1.5
@@ -1,6 +1,6 @@
 /*
    $Source: /v/ossp/cvs/ossp-pkg/petidomo/filter.c,v $
-   $Revision: 1.4 $
+   $Revision: 1.5 $
 
    Copyright (C) 2000 by CyberSolutions GmbH, Germany.
 
@@ -23,6 +23,7 @@
 #include <unistd.h>
 #include <fcntl.h>
 #include <errno.h>
+#include <string.h>
 
 #include "petidomo.h"
 
@@ -61,11 +62,11 @@
     /* Init pipes. */
 
     if (pipe(child_in) == -1) {
-        syslog(LOG_ERR, "Couldn't open a writing-pipe to my child process: %m");
+        syslog(LOG_ERR, "Couldn't open a writing-pipe to my child process: %s", strerror(errno));
         return -1;
     }
     if (pipe(child_out) == -1) {
-        syslog(LOG_ERR, "Couldn't open a read-pipe from my child process: %m");
+        syslog(LOG_ERR, "Couldn't open a read-pipe from my child process: %s", strerror(errno));
         return -1;
     }
 
@@ -78,11 +79,11 @@
           close(child_in[WRITE]);
           close(child_out[READ]);
           if (dup2(child_in[READ], STDIN_FILENO) == -1) {
-              syslog(LOG_ERR, "Child process couldn't read from pipe: %m");
+              syslog(LOG_ERR, "Child process couldn't read from pipe: %s", strerror(errno));
               return -1;
           }
           if (dup2(child_out[WRITE], STDOUT_FILENO) == -1) {
-              syslog(LOG_ERR, "Child process couldn't read from pipe: %m");
+              syslog(LOG_ERR, "Child process couldn't read from pipe: %s", strerror(errno));
               return -1;
           }
           close(child_in[READ]);
@@ -95,7 +96,7 @@
           close(child_in[WRITE]);
           close(child_out[READ]);
           close(child_out[WRITE]);
-          syslog(LOG_ERR, "Couldn't fork: %m");
+          syslog(LOG_ERR, "Couldn't fork: %s", strerror(errno));
           return -1;
       default:
           /* everything is fine */
@@ -107,24 +108,24 @@
 
     rc = fcntl(child_in[WRITE], F_GETFL, 0);
     if (rc == -1) {
-        syslog(LOG_ERR, "Couldn't get flags from write-pipe descriptor: %m");
+        syslog(LOG_ERR, "Couldn't get flags from write-pipe descriptor: %s", strerror(errno));
         goto error_exit;
     }
     rc |= O_NONBLOCK;
     rc = fcntl(child_in[WRITE], F_SETFL, rc);
     if (rc == -1) {
-        syslog(LOG_ERR, "Couldn't set flags for write-pipe descriptor: %m");
+        syslog(LOG_ERR, "Couldn't set flags for write-pipe descriptor: %s", strerror(errno));
         goto error_exit;
     }
     rc = fcntl(child_out[READ], F_GETFL, 0);
     if (rc == -1) {
-        syslog(LOG_ERR, "Couldn't get flags from write-pipe descriptor: %m");
+        syslog(LOG_ERR, "Couldn't get flags from write-pipe descriptor: %s", strerror(errno));
         goto error_exit;
     }
     rc |= O_NONBLOCK;
     rc = fcntl(child_out[READ], F_SETFL, rc);
     if (rc == -1) {
-        syslog(LOG_ERR, "Couldn't set flags for write-pipe descriptor: %m");
+        syslog(LOG_ERR, "Couldn't set flags for write-pipe descriptor: %s", strerror(errno));
         goto error_exit;
     }
 
@@ -167,7 +168,7 @@
                 }
             }
             else if (errno != EAGAIN) {
-                syslog(LOG_ERR, "Writing to the filter process failed: %m");
+                syslog(LOG_ERR, "Writing to the filter process failed: %s", strerror(errno));
                 goto error_exit;
             }
         }
@@ -178,7 +179,7 @@
             newmail_size += 10*1024;
             newmail = realloc(newmail, newmail_size);
             if (newmail == NULL) {
-                syslog(LOG_ERR, "Failed to allocate %d byte of memory: %m", newmail_size);
+                syslog(LOG_ERR, "Failed to allocate %d byte of memory: %s", newmail_size, strerror(errno));
                 goto error_exit;
             }
         }
@@ -190,7 +191,7 @@
             break;              /* we are finished */
         }
         else if (errno != EAGAIN) {
-            syslog(LOG_ERR, "Reading from filter process failed: %m");
+            syslog(LOG_ERR, "Reading from filter process failed: %s", strerror(errno));
             goto error_exit;
         }
     }


ossp-pkg/petidomo/hermes.c 1.13 -> 1.14

--- hermes.c     2001/01/19 14:18:43     1.13
+++ hermes.c     2001/01/19 14:56:33     1.14
@@ -1,6 +1,6 @@
 /*
    $Source: /v/ossp/cvs/ossp-pkg/petidomo/hermes.c,v $
-   $Revision: 1.13 $
+   $Revision: 1.14 $
 
    Copyright (C) 2000 by CyberSolutions GmbH, Germany.
 
@@ -215,8 +215,6 @@
 
             if (g_is_approved)
                 {
-                int rc;
-
                 syslog(LOG_NOTICE, "\"%s\" acknowledged a former posting attempt on ack-once list \"%s\"; " \
                        "add him to the ack file and let the posting pass.", MailStruct->From, listname);
 
@@ -229,7 +227,7 @@
                 }
             else
                 {
-                int rc = is_address_on_list(ListConfig->ack_file, MailStruct->From);
+                rc = is_address_on_list(ListConfig->ack_file, MailStruct->From);
                 if (rc == 0)
                     rc = is_address_on_list(ListConfig->ack_file, MailStruct->Envelope);
                 if (rc < 0)


ossp-pkg/petidomo/index.c 1.7 -> 1.8

--- index.c      2001/01/18 20:30:50     1.7
+++ index.c      2001/01/19 14:56:33     1.8
@@ -1,6 +1,6 @@
 /*
    $Source: /v/ossp/cvs/ossp-pkg/petidomo/index.c,v $
-   $Revision: 1.7 $
+   $Revision: 1.8 $
 
    Copyright (C) 2000 by CyberSolutions GmbH, Germany.
 
@@ -21,6 +21,7 @@
 #include <sys/types.h>
 #include <sys/stat.h>
 #include <dirent.h>
+#include <errno.h>
 
 #include "libtext/text.h"
 #include "petidomo.h"
@@ -53,7 +54,7 @@
 
     fh = vOpenMailer(envelope, address, NULL);
     if (fh == NULL) {
-        syslog(LOG_ERR, "Failed to send mail to \"%s\": %m", address);
+        syslog(LOG_ERR, "Failed to send mail to \"%s\": %s", address, strerror(errno));
         return -1;
     }
     fprintf(fh, "From: %s (Petidomo Mailing List Server)\n", from);


ossp-pkg/petidomo/io.c 1.3 -> 1.4

--- io.c 2001/01/18 20:30:50     1.3
+++ io.c 2001/01/19 14:56:33     1.4
@@ -1,6 +1,6 @@
 /*
    $Source: /v/ossp/cvs/ossp-pkg/petidomo/io.c,v $
-   $Revision: 1.3 $
+   $Revision: 1.4 $
 
    Copyright (C) 2000 by CyberSolutions GmbH, Germany.
 
@@ -20,6 +20,7 @@
 #include <fcntl.h>
 #include <unistd.h>
 #include <errno.h>
+#include <string.h>
 
 #include "petidomo.h"
 
@@ -42,7 +43,7 @@
     for (;;) {
         rc = read(fd, (buffer+read_size), (buffer_size - read_size - 1));
         if (rc == -1) {
-            syslog(LOG_ERR, "Error occured while reading file: %m");
+            syslog(LOG_ERR, "Error occured while reading file: %s", strerror(errno));
             free(buffer);
             return NULL;
         }
@@ -83,7 +84,7 @@
     assert(filename);
 
     if ((fd = open(filename, O_RDONLY, 0)) == -1) {
-        syslog(LOG_WARNING, "open(\"%s\", O_RDONLY): %m", filename);
+        syslog(LOG_WARNING, "open(\"%s\", O_RDONLY): %s", filename, strerror(errno));
         return NULL;
     }
     lock.l_start  = 0;
@@ -92,11 +93,11 @@
     lock.l_whence = SEEK_SET;
     fcntl(fd, F_SETLKW, &lock);
     if ((len = lseek(fd, 0, SEEK_END)) == -1) {
-        syslog(LOG_WARNING, "lseek(\"%s\", SEEK_END): %m", filename);
+        syslog(LOG_WARNING, "lseek(\"%s\", SEEK_END): %s", filename, strerror(errno));
         return NULL;
     }
     if ((lseek(fd, 0, SEEK_SET) == -1)) {
-        syslog(LOG_WARNING, "lseek(\"%s\", SEEK_SET): %m", filename);
+        syslog(LOG_WARNING, "lseek(\"%s\", SEEK_SET): %s", filename, strerror(errno));
         return NULL;
     }
     buffer = malloc(len+1);
@@ -106,7 +107,7 @@
     }
     rc = read(fd, buffer, len);
     if (rc != len) {
-        syslog(LOG_WARNING, "read(\"%s\", %d) read %d byte: %m", filename, len, rc);
+        syslog(LOG_WARNING, "read(\"%s\", %d) read %d byte: %s", filename, len, rc, strerror(errno));
         return NULL;
     }
     buffer[len] = '\0';
@@ -133,12 +134,12 @@
     lock.l_whence = SEEK_SET;
     fcntl(fd, F_SETLKW, &lock);
     if (fd == -1) {
-        syslog(LOG_ERR, "open(\"%s\"): %m", filename);
+        syslog(LOG_ERR, "open(\"%s\"): %s", filename, strerror(errno));
         return -1;
     }
     rc = write(fd, buffer, len);
     if (rc == -1) {
-        syslog(LOG_ERR, "Error occured while writing to file \"%s\": %m", filename);
+        syslog(LOG_ERR, "Error occured while writing to file \"%s\": %s", filename, strerror(errno));
         close(fd);
         return -1;
     }


ossp-pkg/petidomo/libargv/argv.c 1.2 -> 1.3

--- argv.c       2000/12/13 15:37:35     1.2
+++ argv.c       2001/01/19 14:56:34     1.3
@@ -1,7 +1,7 @@
 /*
  * $Source: /v/ossp/cvs/ossp-pkg/petidomo/libargv/argv.c,v $
- * $Revision: 1.2 $
- * $Date: 2000/12/13 15:37:35 $
+ * $Revision: 1.3 $
+ * $Date: 2001/01/19 14:56:34 $
  *
  * Copyright (c) 1999 by Gray Watson <gray.watson@letters.com>.
  * All rights reserved.
@@ -106,7 +106,7 @@
 
 /*** ET: BSD's strsep funktion.  See their man-page... ***/
 
-char *
+static char *
 my_strsep(char **stringp, const char *delim)
 {
     register char *s;


ossp-pkg/petidomo/libconfigfile/config.c 1.3 -> 1.4

--- config.c     2000/12/13 17:37:56     1.3
+++ config.c     2001/01/19 14:56:35     1.4
@@ -1,6 +1,6 @@
 /*
    $Source: /v/ossp/cvs/ossp-pkg/petidomo/libconfigfile/config.c,v $
-   $Revision: 1.3 $
+   $Revision: 1.4 $
 
    Copyright (C) 2000 by CyberSolutions GmbH, Germany.
 
@@ -118,7 +118,7 @@
 
     file_buf = loadfile(filename);
     if (file_buf == NULL) {
-        syslog(LOG_WARNING, "ReadConfig: Failed to load config file \"%s\": %m", filename);
+        syslog(LOG_WARNING, "ReadConfig: Failed to load config file \"%s\": %s", filename, strerror(errno));
         return -1;
     }
 
@@ -126,7 +126,7 @@
 
     filename = strdup(filename);
     if (filename == NULL) {
-        syslog(LOG_ERR, "ReadConfig: Failed to load config file \"%s\": %m", filename);
+        syslog(LOG_ERR, "ReadConfig: Failed to load config file \"%s\": %s", filename, strerror(errno));
         return -1;
     }
     node = AppendNode(Files, filename, file_buf);
@@ -227,7 +227,7 @@
               syslog(LOG_WARNING, "ReadConfig: Method not supported at the moment.");
               break;
           default:
-              syslog(LOG_ERR, "ReadConfig internal error: ConfigFile structure element %d has unknown type %d.", i++, (&(cf[i]))->type);
+              syslog(LOG_ERR, "ReadConfig internal error: ConfigFile structure element %d has unknown type %d.", i, (&(cf[i]))->type);
         }
 
     }
@@ -305,7 +305,7 @@
 
     file_buf = loadfile(filename);
     if (file_buf == NULL) {
-        syslog(LOG_ERR, "GetConfig: Failed to load config file \"%s\". %m", filename);
+        syslog(LOG_ERR, "GetConfig: Failed to load config file \"%s\": %s", filename, strerror(errno));
         return NULL;
     }
 
@@ -382,7 +382,7 @@
 
     file_buf = loadfile(filename);
     if (file_buf == NULL) {
-        syslog(LOG_ERR, "SetConfig: Failed to load config file \"%s\": %m", filename);
+        syslog(LOG_ERR, "SetConfig: Failed to load config file \"%s\": %s", filename, strerror(errno));
         return -1;
     }
     file_len = errno;
@@ -462,7 +462,7 @@
     return 0;
 
 io_error:
-    syslog(LOG_ERR, "SetConfig: Failed to write to file \"%s\": %m", filename);
+    syslog(LOG_ERR, "SetConfig: Failed to write to file \"%s\": %s", filename, strerror(errno));
     free(file_buf);
     return -1;
 }


ossp-pkg/petidomo/librfc822/address.y 1.3 -> 1.4

--- address.y    2000/12/16 13:23:51     1.3
+++ address.y    2001/01/19 14:56:35     1.4
@@ -1,6 +1,6 @@
 /*
    $Source: /v/ossp/cvs/ossp-pkg/petidomo/librfc822/address.y,v $
-   $Revision: 1.3 $
+   $Revision: 1.4 $
 
    Copyright (C) 2000 by CyberSolutions GmbH, Germany.
 
@@ -22,6 +22,7 @@
 
 #define YYSTYPE char *
 
+#include <string.h>
 #include <errno.h>
 #ifdef DEBUG_DMALLOC
 #  include <dmalloc.h>


ossp-pkg/petidomo/librfc822/decomment.c 1.3 -> 1.4

--- decomment.c  2000/12/16 13:27:12     1.3
+++ decomment.c  2001/01/19 14:56:35     1.4
@@ -1,6 +1,6 @@
 /*
    $Source: /v/ossp/cvs/ossp-pkg/petidomo/librfc822/decomment.c,v $
-   $Revision: 1.3 $
+   $Revision: 1.4 $
 
    Copyright (C) 2000 by CyberSolutions GmbH, Germany.
 
@@ -21,6 +21,7 @@
 #include <stdlib.h>
 #include <errno.h>
 #include <assert.h>
+#include <string.h>
 #ifdef DEBUG_DMALLOC
 #  include <dmalloc.h>
 #endif


ossp-pkg/petidomo/mailer.c 1.5 -> 1.6

--- mailer.c     2001/01/18 20:30:50     1.5
+++ mailer.c     2001/01/19 14:56:33     1.6
@@ -1,6 +1,6 @@
 /*
    $Source: /v/ossp/cvs/ossp-pkg/petidomo/mailer.c,v $
-   $Revision: 1.5 $
+   $Revision: 1.6 $
 
    Copyright (C) 2000 by CyberSolutions GmbH, Germany.
 
@@ -23,6 +23,8 @@
 #include <sys/wait.h>
 #include <unistd.h>
 #include <ctype.h>
+#include <string.h>
+#include <errno.h>
 
 #include "libtext/text.h"
 #include "petidomo.h"
@@ -112,7 +114,7 @@
 
     fh = popen(cmdline, "w");
     if (fh == NULL)
-        syslog(LOG_ERR, "Failed opening pipe to \"%s\": %m", cmdline);
+        syslog(LOG_ERR, "Failed opening pipe to \"%s\": %s", cmdline, strerror(errno));
 
     free(cmdline);
     return fh;
@@ -218,7 +220,7 @@
         arguments[counter++] = NULL;
         if (pipe(fildes) == -1)
             {
-            syslog(LOG_ERR, "Couldn't open a pipe to my child process: %m");
+            syslog(LOG_ERR, "Couldn't open a pipe to my child process: %s", strerror(errno));
             return -1;
             }
         child_pid = fork();
@@ -229,16 +231,16 @@
                 close(MYPIPE_WRITE);
                 if (dup2(MYPIPE_READ, STDIN_FILENO) == -1)
                     {
-                    syslog(LOG_ERR, "Child process couldn't read from pipe: %m");
+                    syslog(LOG_ERR, "Child process couldn't read from pipe: %s", strerror(errno));
                     return -1;
                     }
                 close(MYPIPE_READ);
                 execv(MasterConfig->mta, arguments);
-                syslog(LOG_ERR, "Couldn't exec(\"%s\"): %m", MasterConfig->mta);
+                syslog(LOG_ERR, "Couldn't exec(\"%s\"): %s", MasterConfig->mta, strerror(errno));
                 return -1;
             case -1:
                 /* Error */
-                syslog(LOG_ERR, "Couldn't fork: %m");
+                syslog(LOG_ERR, "Couldn't fork: %s", strerror(errno));
                 return -1;
             default:
                 /* everything is fine */


ossp-pkg/petidomo/members.c 1.8 -> 1.9

--- members.c    2001/01/18 20:30:50     1.8
+++ members.c    2001/01/19 14:56:33     1.9
@@ -1,6 +1,6 @@
 /*
    $Source: /v/ossp/cvs/ossp-pkg/petidomo/members.c,v $
-   $Revision: 1.8 $
+   $Revision: 1.9 $
 
    Copyright (C) 2000 by CyberSolutions GmbH, Germany.
 
@@ -21,6 +21,7 @@
 #include <sys/stat.h>
 #include <dirent.h>
 #include <ctype.h>
+#include <string.h>
 
 #include "libtext/text.h"
 #include "petidomo.h"


ossp-pkg/petidomo/password.c 1.4 -> 1.5

--- password.c   2001/01/18 20:30:50     1.4
+++ password.c   2001/01/19 14:56:33     1.5
@@ -1,6 +1,6 @@
 /*
    $Source: /v/ossp/cvs/ossp-pkg/petidomo/password.c,v $
-   $Revision: 1.4 $
+   $Revision: 1.5 $
 
    Copyright (C) 2000 by CyberSolutions GmbH, Germany.
 
@@ -18,6 +18,7 @@
 */
 
 #include <ctype.h>
+#include <string.h>
 #include "petidomo.h"
 
 static const char * s_password = NULL;


ossp-pkg/petidomo/queue_command.c 1.5 -> 1.6

--- queue_command.c      2001/01/19 14:53:23     1.5
+++ queue_command.c      2001/01/19 14:56:33     1.6
@@ -1,6 +1,6 @@
 /*
    $Source: /v/ossp/cvs/ossp-pkg/petidomo/Attic/queue_command.c,v $
-   $Revision: 1.5 $
+   $Revision: 1.6 $
 
    Copyright (C) 2000 by Peter Simons <simons@computer.org>.
 
@@ -17,6 +17,8 @@
    General Public License for more details.
 */
 
+#include <string.h>
+#include <errno.h>
 #include <sys/types.h>
 #include <sys/stat.h>
 #include "libtext/text.h"
@@ -34,7 +36,7 @@
     fh = fopen(buffer, "w");
     if (fh == NULL)
         {
-        syslog(LOG_ERR, "Opening ack spool file \"%s\" failed: %m", buffer);
+        syslog(LOG_ERR, "Opening ack spool file \"%s\" failed: %s", buffer, strerror(errno));
         exit(1);
         }
     fprintf(fh, "#! /bin/sh\n");


ossp-pkg/petidomo/queue_posting.c 1.5 -> 1.6

--- queue_posting.c      2001/01/19 14:53:23     1.5
+++ queue_posting.c      2001/01/19 14:56:33     1.6
@@ -1,6 +1,6 @@
 /*
    $Source: /v/ossp/cvs/ossp-pkg/petidomo/Attic/queue_posting.c,v $
-   $Revision: 1.5 $
+   $Revision: 1.6 $
 
    Copyright (C) 2000 by Peter Simons <simons@computer.org>.
 
@@ -17,6 +17,8 @@
    General Public License for more details.
 */
 
+#include <string.h>
+#include <errno.h>
 #include <sys/types.h>
 #include <sys/stat.h>
 #include "libtext/text.h"
@@ -34,7 +36,7 @@
     fh = fopen(buffer, "w");
     if (fh == NULL)
         {
-        syslog(LOG_ERR, "Opening ack spool file \"%s\" failed: %m", buffer);
+        syslog(LOG_ERR, "Opening ack spool file \"%s\" failed: %s", buffer, strerror(errno));
         exit(1);
         }
     fprintf(fh, "#! /bin/sh\n");


ossp-pkg/petidomo/subscribe.c 1.18 -> 1.19

--- subscribe.c  2001/01/19 14:28:08     1.18
+++ subscribe.c  2001/01/19 14:56:33     1.19
@@ -1,6 +1,6 @@
 /*
    $Source: /v/ossp/cvs/ossp-pkg/petidomo/subscribe.c,v $
-   $Revision: 1.18 $
+   $Revision: 1.19 $
 
    Copyright (C) 2000 by CyberSolutions GmbH, Germany.
 
@@ -18,6 +18,8 @@
 */
 
 #include <string.h>
+#include <errno.h>
+
 #include "libtext/text.h"
 #include "petidomo.h"
 
@@ -291,7 +293,7 @@
     fh = fopen(ListConfig->address_file, "a");
     if (fh == NULL)
         {
-        syslog(LOG_ERR, "Failed to open file \"%s\" for writing: %m", ListConfig->address_file);
+        syslog(LOG_ERR, "Failed to open file \"%s\" for writing: %s", ListConfig->address_file, strerror(errno));
         return -1;
         }
     fprintf(fh, "%s\n", address);


ossp-pkg/petidomo/unsubscribe.c 1.17 -> 1.18

--- unsubscribe.c        2001/01/19 14:28:08     1.17
+++ unsubscribe.c        2001/01/19 14:56:33     1.18
@@ -1,6 +1,6 @@
 /*
    $Source: /v/ossp/cvs/ossp-pkg/petidomo/unsubscribe.c,v $
-   $Revision: 1.17 $
+   $Revision: 1.18 $
 
    Copyright (C) 2000 by CyberSolutions GmbH, Germany.
 
@@ -18,6 +18,8 @@
 */
 
 #include <string.h>
+#include <errno.h>
+
 #include "libtext/text.h"
 #include "petidomo.h"
 
@@ -293,7 +295,7 @@
         fh = fopen(ListConfig->address_file, "w");
         if (fh == NULL)
             {
-            syslog(LOG_ERR, "Failed to open file \"%s\" for writing: %m", ListConfig->address_file);
+            syslog(LOG_ERR, "Failed to open file \"%s\" for writing: %s", ListConfig->address_file, strerror(errno));
             return -1;
             }
         *p++ = '\0';

CVSTrac 2.0.1