]> git.ipfire.org Git - thirdparty/tor.git/commitdiff
Make some more verbose gcc warnings go away.
authorNick Mathewson <nickm@torproject.org>
Thu, 22 Jun 2006 07:34:04 +0000 (07:34 +0000)
committerNick Mathewson <nickm@torproject.org>
Thu, 22 Jun 2006 07:34:04 +0000 (07:34 +0000)
svn:r6680

src/or/dirserv.c
src/or/test.c

index b311bc6c1685244005394b5181ddd1c0fe9c8e8d..ad81692d2e28b3c66e3b87bc2c854c96c2f2b489 100644 (file)
@@ -1808,7 +1808,7 @@ connection_dirserv_add_servers_to_outbuf(connection_t *conn)
 
   while (smartlist_len(conn->fingerprint_stack) &&
          buf_datalen(conn->outbuf) < DIRSERV_BUFFER_MIN) {
-    char *body;
+    const char *body;
     char *fp = smartlist_pop_last(conn->fingerprint_stack);
     signed_descriptor_t *sd = NULL;
     if (by_fp) {
index 732456115dac844e666ea073b254f5db15697053..bb13e25176479740e76fdcf973e25744c4fb5af5 100644 (file)
@@ -1002,15 +1002,15 @@ test_gzip(void)
   len1 = 1024;
   ccp2 = "ABCDEFGHIJABCDEFGHIJ";
   len2 = 21;
-  test_eq(tor_zlib_process(state, &cp1, &len1, &ccp2, &len2, 0),
-          TOR_ZLIB_OK);
+  test_assert(tor_zlib_process(state, &cp1, &len1, &ccp2, &len2, 0)
+              == TOR_ZLIB_OK);
   test_eq(len2, 0); /* Make sure we compressed it all. */
   test_assert(cp1 > buf1);
 
   len2 = 0;
   cp2 = cp1;
-  test_eq(tor_zlib_process(state, &cp1, &len1, &ccp2, &len2, 1),
-          TOR_ZLIB_DONE);
+  test_assert(tor_zlib_process(state, &cp1, &len1, &ccp2, &len2, 1)
+              == TOR_ZLIB_DONE);
   test_eq(len2, 0);
   test_assert(cp1 > cp2); /* Make sure we really added something. */
 
@@ -1643,6 +1643,8 @@ main(int c, char**v)
 {
   or_options_t *options = options_new();
   char *errmsg = NULL;
+  (void) c;
+  (void) v;
   options->command = CMD_RUN_UNITTESTS;
   network_init();
   setup_directory();