BIND 10 master, updated. fad3309ccd7794b44b8ee38d5ec0d189e1b4f3b0 [master] Clean fix for unused variables warning.

BIND 10 source code commits bind10-changes at lists.isc.org
Tue May 29 09:49:05 UTC 2012


The branch, master has been updated
       via  fad3309ccd7794b44b8ee38d5ec0d189e1b4f3b0 (commit)
      from  39dcfd79bb1b79812838c7b2f1eb146519f9cf7e (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit fad3309ccd7794b44b8ee38d5ec0d189e1b4f3b0
Author: Marcin Siodelski <marcin at isc.org>
Date:   Tue May 29 11:36:43 2012 +0200

    [master] Clean fix for unused variables warning.

-----------------------------------------------------------------------

Summary of changes:
 tests/tools/perfdhcp/perfdhcp.cc |   16 +++-------------
 1 file changed, 3 insertions(+), 13 deletions(-)

-----------------------------------------------------------------------
diff --git a/tests/tools/perfdhcp/perfdhcp.cc b/tests/tools/perfdhcp/perfdhcp.cc
index 5ed94ee..95bae3d 100644
--- a/tests/tools/perfdhcp/perfdhcp.cc
+++ b/tests/tools/perfdhcp/perfdhcp.cc
@@ -29,16 +29,8 @@
 #include <stdio.h>
 
 int
-main(const int argc, char* const argv[])
+main(const int, char* const*)
 {
-    // We need to manipulate argc and argv to avoid
-    // unused-variable warnings.
-    // This is temporary solution.
-    int ac = argc;
-    char* av = argv[0];
-    if (ac >= 0 && av != 0) {
-        ac = 1;
-    }
     fprintf(stderr, "perfdhcp is not supported on this version of the operating system\n");
     return (1);
 }
@@ -446,14 +438,12 @@ size_t reqaddr_request6;
 /// @param tp timespec structure
 ///
 /// @return always zero (kept for compatibility reasons)
-int clock_gettime(int clockid, struct timespec *tp) {
-
+int clock_gettime(int, struct timespec *tp) {
     struct timeval tv;
-    int unused_id = clockid;
     gettimeofday(&tv, NULL);
     unused_id = 0;
     tp->tv_sec = tv.tv_sec;
-    tp->tv_nsec = tv.tv_usec*1000 + unused_id;
+    tp->tv_nsec = tv.tv_usec*1000;
 
     return (0);
 }



More information about the bind10-changes mailing list