[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

[or-cvs] Fix all warnings on win32 build



Update of /home/or/cvsroot/src/or
In directory moria.mit.edu:/tmp/cvs-serv23620/src/or

Modified Files:
	connection_edge.c dirserv.c or.h rephist.c 
Log Message:
Fix all warnings on win32 build

Index: connection_edge.c
===================================================================
RCS file: /home/or/cvsroot/src/or/connection_edge.c,v
retrieving revision 1.198
retrieving revision 1.199
diff -u -d -r1.198 -r1.199
--- connection_edge.c	21 Jul 2004 03:16:24 -0000	1.198
+++ connection_edge.c	3 Aug 2004 23:57:05 -0000	1.199
@@ -668,7 +668,7 @@
  * Otherwise, send back a reply based on whether <b>success</b> is 1 or 0.
  */
 void connection_ap_handshake_socks_reply(connection_t *conn, char *reply,
-                                         int replylen, char success) {
+                                         int replylen, int success) {
   char buf[256];
 
   if(replylen) { /* we already have a reply in mind */

Index: dirserv.c
===================================================================
RCS file: /home/or/cvsroot/src/or/dirserv.c,v
retrieving revision 1.69
retrieving revision 1.70
diff -u -d -r1.69 -r1.70
--- dirserv.c	22 Jul 2004 23:21:12 -0000	1.69
+++ dirserv.c	3 Aug 2004 23:57:05 -0000	1.70
@@ -696,8 +696,9 @@
   char *s, *cp;
   char digest[DIGEST_LEN];
   char signature[PK_BYTES];
-  int i, len;
-  char published[33];
+  int i;
+  char published[33];
+  size_t len;
   time_t published_on;
 
   len = 1024+(MAX_HEX_NICKNAME_LEN+2)*smartlist_len(descriptor_list);

Index: or.h
===================================================================
RCS file: /home/or/cvsroot/src/or/or.h,v
retrieving revision 1.394
retrieving revision 1.395
diff -u -d -r1.394 -r1.395
--- or.h	22 Jul 2004 22:15:36 -0000	1.394
+++ or.h	3 Aug 2004 23:57:05 -0000	1.395
@@ -1094,7 +1094,7 @@
 
 int connection_ap_make_bridge(char *address, uint16_t port);
 void connection_ap_handshake_socks_reply(connection_t *conn, char *reply,
-                                         int replylen, char success);
+                                         int replylen, int success);
 void connection_ap_handshake_socks_resolved(connection_t *conn,
                                             int answer_type,
                                             int answer_len,

Index: rephist.c
===================================================================
RCS file: /home/or/cvsroot/src/or/rephist.c,v
retrieving revision 1.17
retrieving revision 1.18
diff -u -d -r1.17 -r1.18
--- rephist.c	20 Jul 2004 23:31:00 -0000	1.17
+++ rephist.c	3 Aug 2004 23:57:05 -0000	1.18
@@ -468,9 +468,9 @@
   r = find_largest_max(read_array);
   w = find_largest_max(write_array);
   if (r>w)
-    return w/(double)NUM_SECS_ROLLING_MEASURE;
+    return (int)(w/(double)NUM_SECS_ROLLING_MEASURE);
   else
-    return r/(double)NUM_SECS_ROLLING_MEASURE;
+    return (int)(r/(double)NUM_SECS_ROLLING_MEASURE);
 
   return 0;
 }