[exim-cvs] Compiler quietening

Góra strony
Delete this message
Reply to this message
Autor: Exim Git Commits Mailing List
Data:  
Dla: exim-cvs
Temat: [exim-cvs] Compiler quietening
Gitweb: http://git.exim.org/exim.git/commitdiff/dd4c8678de8ed13eedcf543b301b92216f6352de
Commit:     dd4c8678de8ed13eedcf543b301b92216f6352de
Parent:     0160bfb8f6435449f80ccd8a8d20a0d749c0624d
Author:     Jeremy Harris <jgh146exb@???>
AuthorDate: Sat Oct 18 18:51:16 2014 +0100
Committer:  Jeremy Harris <jgh146exb@???>
CommitDate: Mon Oct 20 19:31:35 2014 +0100


    Compiler quietening
---
 test/src/client.c |    6 +++---
 test/src/fd.c     |    3 ++-
 2 files changed, 5 insertions(+), 4 deletions(-)


diff --git a/test/src/client.c b/test/src/client.c
index e7210f2..b97aa54 100644
--- a/test/src/client.c
+++ b/test/src/client.c
@@ -518,7 +518,7 @@ while (argc >= argi + 1 && argv[argi][0] == '-')
       strcmp(argv[argi], "--help") == 0 ||
       strcmp(argv[argi], "-h") == 0)
     {
-    printf(HELP_MESSAGE);
+    puts(HELP_MESSAGE);
     exit(0);
     }
   if (strcmp(argv[argi], "-tls-on-connect") == 0)
@@ -549,13 +549,13 @@ while (argc >= argi + 1 && argv[argi][0] == '-')
       }
     if (tmplong > 10000L)
       {
-      fprintf(stderr, "Unreasonably long wait of %d seconds requested\n",
+      fprintf(stderr, "Unreasonably long wait of %ld seconds requested\n",
         tmplong);
       exit(1);
       }
     if (tmplong < 0L)
       {
-      fprintf(stderr, "Timeout must not be negative (%d)\n", tmplong);
+      fprintf(stderr, "Timeout must not be negative (%ld)\n", tmplong);
       exit(1);
       }
     timeout = (int) tmplong;
diff --git a/test/src/fd.c b/test/src/fd.c
index 12a8dbc..2dc12c6 100644
--- a/test/src/fd.c
+++ b/test/src/fd.c
@@ -50,7 +50,8 @@ if (filter)
   {
   int len;
   while ((len = read(0, buffer, sizeof(buffer))) > 0)
-    write(1, buffer, len);
+    if (write(1, buffer, len) < 0)
+    exit(1);
   }


p += sprintf(p, "max fd = %d\n", (int)mac_maxfd);