gnunet-svn
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[GNUnet-SVN] [libmicrohttpd] branch master updated (28f723b2 -> 424abcd2


From: gnunet
Subject: [GNUnet-SVN] [libmicrohttpd] branch master updated (28f723b2 -> 424abcd2)
Date: Tue, 31 Oct 2017 09:19:50 +0100

This is an automated email from the git hooks/post-receive script.

karlson2k pushed a change to branch master
in repository libmicrohttpd.

    from 28f723b2 Silenced compiler warnings in src/testcurl/https, minor fixes.
     new e7f77103 Silenced compiler warnings in src/testczzuf.
     new 424abcd2 Additional compiler warnings fixes.

The 2 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 src/examples/demo.c                           | 1 +
 src/examples/demo_https.c                     | 3 ++-
 src/testcurl/https/tls_test_common.c          | 6 +++---
 src/testcurl/test_digestauth.c                | 2 +-
 src/testcurl/test_digestauth_with_arguments.c | 2 +-
 src/testcurl/test_get_response_cleanup.c      | 4 ++++
 src/testzzuf/test_get.c                       | 2 ++
 src/testzzuf/test_get_chunked.c               | 3 +++
 src/testzzuf/test_long_header.c               | 5 +++++
 src/testzzuf/test_post.c                      | 5 +++++
 src/testzzuf/test_post_form.c                 | 5 +++++
 src/testzzuf/test_put.c                       | 2 ++
 src/testzzuf/test_put_chunked.c               | 2 ++
 src/testzzuf/test_put_large.c                 | 2 ++
 14 files changed, 38 insertions(+), 6 deletions(-)

diff --git a/src/examples/demo.c b/src/examples/demo.c
index 0b177357..6c9ad049 100644
--- a/src/examples/demo.c
+++ b/src/examples/demo.c
@@ -832,6 +832,7 @@ generate_page (void *cls,
 static void
 catcher (int sig)
 {
+  (void)sig;   /* Unused. Silent compiler warning. */
   /* do nothing */
 }
 
diff --git a/src/examples/demo_https.c b/src/examples/demo_https.c
index 85c369b6..806464a2 100644
--- a/src/examples/demo_https.c
+++ b/src/examples/demo_https.c
@@ -831,6 +831,7 @@ generate_page (void *cls,
 static void
 catcher (int sig)
 {
+  (void)sig;   /* Unused. Silent compiler warning. */
   /* do nothing */
 }
 
@@ -839,7 +840,7 @@ catcher (int sig)
  * setup handlers to ignore SIGPIPE.
  */
 static void
-ignore_sigpipe ()
+ignore_sigpipe (void)
 {
   struct sigaction oldsig;
   struct sigaction sig;
diff --git a/src/testcurl/https/tls_test_common.c 
b/src/testcurl/https/tls_test_common.c
index 54466a2a..be13ad36 100644
--- a/src/testcurl/https/tls_test_common.c
+++ b/src/testcurl/https/tls_test_common.c
@@ -27,8 +27,6 @@
 #include "tls_test_keys.h"
 
 
-int curl_check_version (const char *req_version, ...);
-
 FILE *
 setup_ca_cert ()
 {
@@ -278,13 +276,15 @@ gen_test_file_url (char *url,
   int ret = 0;
   char *doc_path;
   size_t doc_path_len;
-  size_t i;
   /* setup test file path, url */
 #ifdef PATH_MAX
   doc_path_len = PATH_MAX > 4096 ? 4096 : PATH_MAX;
 #else  /* ! PATH_MAX */
   doc_path_len = 4096;
 #endif /* ! PATH_MAX */
+#ifdef WINDOWS
+  size_t i;
+#endif /* ! WINDOWS */
   if (NULL == (doc_path = malloc (doc_path_len)))
     {
       fprintf (stderr, MHD_E_MEM);
diff --git a/src/testcurl/test_digestauth.c b/src/testcurl/test_digestauth.c
index e107da2a..48c7a87a 100644
--- a/src/testcurl/test_digestauth.c
+++ b/src/testcurl/test_digestauth.c
@@ -170,7 +170,7 @@ testDigestAuth ()
   while (off < 8)
     {
       len = read(fd, rnd, 8);
-      if (len == -1)
+      if (len == (size_t)-1)
         {
           fprintf(stderr, "Failed to read `%s': %s\n",
                   "/dev/urandom",
diff --git a/src/testcurl/test_digestauth_with_arguments.c 
b/src/testcurl/test_digestauth_with_arguments.c
index 72578376..107d2256 100644
--- a/src/testcurl/test_digestauth_with_arguments.c
+++ b/src/testcurl/test_digestauth_with_arguments.c
@@ -165,7 +165,7 @@ testDigestAuth ()
   while (off < 8)
        {
          len = read(fd, rnd, 8);
-         if (len == -1)
+         if (len == (size_t)-1)
            {
                  fprintf(stderr, "Failed to read `%s': %s\n",
                       "/dev/urandom",
diff --git a/src/testcurl/test_get_response_cleanup.c 
b/src/testcurl/test_get_response_cleanup.c
index d2ab119d..0189a1c1 100644
--- a/src/testcurl/test_get_response_cleanup.c
+++ b/src/testcurl/test_get_response_cleanup.c
@@ -95,6 +95,8 @@ kill_curl (pid_t pid)
 static ssize_t
 push_callback (void *cls, uint64_t pos, char *buf, size_t max)
 {
+  (void)cls;(void)pos; /* Unused. Silent compiler warning. */
+
   if (max == 0)
     return 0;
   buf[0] = 'd';
@@ -125,6 +127,8 @@ ahc_echo (void *cls,
   const char *me = cls;
   struct MHD_Response *response;
   int ret;
+  (void)url;(void)version;                      /* Unused. Silent compiler 
warning. */
+  (void)upload_data;(void)upload_data_size;     /* Unused. Silent compiler 
warning. */
 
   //fprintf (stderr, "In CB: %s!\n", method);
   if (0 != strcmp (me, method))
diff --git a/src/testzzuf/test_get.c b/src/testzzuf/test_get.c
index 3ae2e89e..503aee44 100644
--- a/src/testzzuf/test_get.c
+++ b/src/testzzuf/test_get.c
@@ -72,6 +72,7 @@ ahc_echo (void *cls,
   const char *me = cls;
   struct MHD_Response *response;
   int ret;
+  (void)version;(void)upload_data;(void)upload_data_size;       /* Unused. 
Silent compiler warning. */
 
   if (0 != strcmp (me, method))
     return MHD_NO;              /* unexpected method */
@@ -299,6 +300,7 @@ int
 main (int argc, char *const *argv)
 {
   unsigned int errorCount = 0;
+  (void)argc;   /* Unused. Silent compiler warning. */
 
   oneone = (NULL != strrchr (argv[0], (int) '/')) ?
     (NULL != strstr (strrchr (argv[0], (int) '/'), "11")) : 0;
diff --git a/src/testzzuf/test_get_chunked.c b/src/testzzuf/test_get_chunked.c
index fecc71ce..3e274e7f 100644
--- a/src/testzzuf/test_get_chunked.c
+++ b/src/testzzuf/test_get_chunked.c
@@ -99,6 +99,8 @@ ahc_echo (void *cls,
   struct MHD_Response *response;
   struct MHD_Response **responseptr;
   int ret;
+  (void)url;(void)version;                      /* Unused. Silent compiler 
warning. */
+  (void)upload_data;(void)upload_data_size;     /* Unused. Silent compiler 
warning. */
 
   if (0 != strcmp (me, method))
     return MHD_NO;              /* unexpected method */
@@ -317,6 +319,7 @@ int
 main (int argc, char *const *argv)
 {
   unsigned int errorCount = 0;
+  (void)argc; (void)argv; /* Unused. Silent compiler warning. */
 
   if (0 != curl_global_init (CURL_GLOBAL_WIN32))
     return 2;
diff --git a/src/testzzuf/test_long_header.c b/src/testzzuf/test_long_header.c
index 6e3f15bf..26932ea0 100644
--- a/src/testzzuf/test_long_header.c
+++ b/src/testzzuf/test_long_header.c
@@ -50,6 +50,7 @@ static int oneone;
 static int
 apc_all (void *cls, const struct sockaddr *addr, socklen_t addrlen)
 {
+  (void)cls;(void)addr;(void)addrlen;   /* Unused. Silent compiler warning. */
   return MHD_YES;
 }
 
@@ -63,6 +64,7 @@ struct CBC
 static size_t
 copyBuffer (void *ptr, size_t size, size_t nmemb, void *ctx)
 {
+  (void)ptr;(void)ctx;  /* Unused. Silent compiler warning. */
   return size * nmemb;
 }
 
@@ -78,6 +80,8 @@ ahc_echo (void *cls,
   const char *me = cls;
   struct MHD_Response *response;
   int ret;
+  (void)version;(void)upload_data;      /* Unused. Silent compiler warning. */
+  (void)upload_data_size;(void)unused;  /* Unused. Silent compiler warning. */
 
   if (0 != strcmp (me, method))
     return MHD_NO;              /* unexpected method */
@@ -220,6 +224,7 @@ int
 main (int argc, char *const *argv)
 {
   unsigned int errorCount = 0;
+  (void)argc;   /* Unused. Silent compiler warning. */
 
   oneone = (NULL != strrchr (argv[0], (int) '/')) ?
     (NULL != strstr (strrchr (argv[0], (int) '/'), "11")) : 0;
diff --git a/src/testzzuf/test_post.c b/src/testzzuf/test_post.c
index b91de32b..51e67593 100644
--- a/src/testzzuf/test_post.c
+++ b/src/testzzuf/test_post.c
@@ -58,6 +58,7 @@ completed_cb (void *cls,
              enum MHD_RequestTerminationCode toe)
 {
   struct MHD_PostProcessor *pp = *con_cls;
+  (void)cls;(void)connection;(void)toe; /* Unused. Silent compiler warning. */
 
   if (NULL != pp)
     MHD_destroy_post_processor (pp);
@@ -93,6 +94,8 @@ post_iterator (void *cls,
                const char *value, uint64_t off, size_t size)
 {
   int *eok = cls;
+  (void)kind;(void)filename;(void)content_type; /* Unused. Silent compiler 
warning. */
+  (void)transfer_encoding;(void)off;            /* Unused. Silent compiler 
warning. */
 
   if ((0 == strcmp (key, "name")) &&
       (size == strlen ("daniel")) && (0 == strncmp (value, "daniel", size)))
@@ -116,6 +119,7 @@ ahc_echo (void *cls,
   struct MHD_Response *response;
   struct MHD_PostProcessor *pp;
   int ret;
+  (void)cls;(void)version;      /* Unused. Silent compiler warning. */
 
   if (0 != strcmp ("POST", method))
     {
@@ -379,6 +383,7 @@ int
 main (int argc, char *const *argv)
 {
   unsigned int errorCount = 0;
+  (void)argc;   /* Unused. Silent compiler warning. */
 
   oneone = (NULL != strrchr (argv[0], (int) '/')) ?
     (NULL != strstr (strrchr (argv[0], (int) '/'), "11")) : 0;
diff --git a/src/testzzuf/test_post_form.c b/src/testzzuf/test_post_form.c
index dbf22b9c..60b0fe35 100644
--- a/src/testzzuf/test_post_form.c
+++ b/src/testzzuf/test_post_form.c
@@ -56,6 +56,7 @@ completed_cb (void *cls,
              enum MHD_RequestTerminationCode toe)
 {
   struct MHD_PostProcessor *pp = *con_cls;
+  (void)cls;(void)connection;(void)toe;            /* Unused. Silent compiler 
warning. */
 
   if (NULL != pp)
     MHD_destroy_post_processor (pp);
@@ -90,6 +91,8 @@ post_iterator (void *cls,
                const char *value, uint64_t off, size_t size)
 {
   int *eok = cls;
+  (void)kind;(void)filename;(void)content_type; /* Unused. Silent compiler 
warning. */
+  (void)transfer_encoding;(void)off;            /* Unused. Silent compiler 
warning. */
 
   if (key == NULL)
     return MHD_YES;
@@ -119,6 +122,7 @@ ahc_echo (void *cls,
   struct MHD_Response *response;
   struct MHD_PostProcessor *pp;
   int ret;
+  (void)cls;(void)version;      /* Unused. Silent compiler warning. */
 
   if (0 != strcmp ("POST", method))
     {
@@ -395,6 +399,7 @@ int
 main (int argc, char *const *argv)
 {
   unsigned int errorCount = 0;
+  (void)argc;   /* Unused. Silent compiler warning. */
 
   oneone = (NULL != strrchr (argv[0], (int) '/')) ?
     (NULL != strstr (strrchr (argv[0], (int) '/'), "11")) : 0;
diff --git a/src/testzzuf/test_put.c b/src/testzzuf/test_put.c
index f76cde58..cc02b5c1 100644
--- a/src/testzzuf/test_put.c
+++ b/src/testzzuf/test_put.c
@@ -86,6 +86,7 @@ ahc_echo (void *cls,
   int *done = cls;
   struct MHD_Response *response;
   int ret;
+  (void)version;(void)unused;   /* Unused. Silent compiler warning. */
 
   if (0 != strcmp ("PUT", method))
     return MHD_NO;              /* unexpected method */
@@ -346,6 +347,7 @@ int
 main (int argc, char *const *argv)
 {
   unsigned int errorCount = 0;
+  (void)argc;   /* Unused. Silent compiler warning. */
 
   oneone = (NULL != strrchr (argv[0], (int) '/')) ?
     (NULL != strstr (strrchr (argv[0], (int) '/'), "11")) : 0;
diff --git a/src/testzzuf/test_put_chunked.c b/src/testzzuf/test_put_chunked.c
index a1527599..87d7f7e8 100644
--- a/src/testzzuf/test_put_chunked.c
+++ b/src/testzzuf/test_put_chunked.c
@@ -87,6 +87,7 @@ ahc_echo (void *cls,
   struct MHD_Response *response;
   int ret;
   int have;
+  (void)version;(void)unused;   /* Unused. Silent compiler warning. */
 
   if (0 != strcmp ("PUT", method))
     return MHD_NO;              /* unexpected method */
@@ -358,6 +359,7 @@ int
 main (int argc, char *const *argv)
 {
   unsigned int errorCount = 0;
+  (void)argc; (void)argv; /* Unused. Silent compiler warning. */
 
   if (0 != curl_global_init (CURL_GLOBAL_WIN32))
     return 2;
diff --git a/src/testzzuf/test_put_large.c b/src/testzzuf/test_put_large.c
index af0d1706..d52e7b91 100644
--- a/src/testzzuf/test_put_large.c
+++ b/src/testzzuf/test_put_large.c
@@ -94,6 +94,7 @@ ahc_echo (void *cls,
   int *done = cls;
   struct MHD_Response *response;
   int ret;
+  (void)version;(void)unused;  /* Unused. Silent compiler warning. */
 
   if (0 != strcmp ("PUT", method))
     return MHD_NO;              /* unexpected method */
@@ -364,6 +365,7 @@ int
 main (int argc, char *const *argv)
 {
   unsigned int errorCount = 0;
+  (void)argc;  /* Unused. Silent compiler warning. */
 
   oneone = (NULL != strrchr (argv[0], (int) '/')) ?
     (NULL != strstr (strrchr (argv[0], (int) '/'), "11")) : 0;

-- 
To stop receiving notification emails like this one, please contact
address@hidden



reply via email to

[Prev in Thread] Current Thread [Next in Thread]