Warnings removal pass: always include config.h first; add a few
authorIvo Timmermans <ivo@lychnis.net>
Fri, 3 Nov 2000 22:35:12 +0000 (22:35 +0000)
committerIvo Timmermans <ivo@lychnis.net>
Fri, 3 Nov 2000 22:35:12 +0000 (22:35 +0000)
prototypes in the header files.

This also fixes a few lint errors/warnings.

src/conf.c
src/connlist.c
src/connlist.h
src/protocol.c
src/protocol.h
src/subnet.c

index 7780a0b23200a0f2732c7b9f228293aaf86c8384..477d0fd8c89562fb58dd49396e72ff3d02f3db63 100644 (file)
     along with this program; if not, write to the Free Software
     Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
 
-    $Id: conf.c,v 1.9.4.19 2000/10/29 00:24:31 guus Exp $
+    $Id: conf.c,v 1.9.4.20 2000/11/03 22:35:10 zarq Exp $
 */
 
+#include "config.h"
 
 #include <ctype.h>
 #include <errno.h>
@@ -30,7 +31,6 @@
 #include <stdlib.h>
 #include <string.h>
 #include <syslog.h>
-#include <stdio.h>
 
 #include <xalloc.h>
 
index ac6970b5825fe00e7e382a4a4ef87c6e3d490e4b..89b11fbe256879982c776096ca2305122de992e8 100644 (file)
     along with this program; if not, write to the Free Software
     Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
 
-    $Id: connlist.c,v 1.1.2.11 2000/10/29 02:07:39 guus Exp $
+    $Id: connlist.c,v 1.1.2.12 2000/11/03 22:35:10 zarq Exp $
 */
 
+#include "config.h"
+
+#include <stdio.h>
 #include <syslog.h>
 
 #include "net.h"       /* Don't ask. */
index 69bef9ee00288dd2622e4b97f4879d5605499be4..8f974c97442b90f0bb9ffd64f994f2cc36fa0ccc 100644 (file)
@@ -17,7 +17,7 @@
     along with this program; if not, write to the Free Software
     Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
 
-    $Id: connlist.h,v 1.1.2.9 2000/10/29 22:55:14 guus Exp $
+    $Id: connlist.h,v 1.1.2.10 2000/11/03 22:35:10 zarq Exp $
 */
 
 #ifndef __TINC_CONNLIST_H__
@@ -109,5 +109,7 @@ extern void conn_list_del(conn_list_t *);
 extern conn_list_t *lookup_id(char *);
 extern void dump_conn_list(void);
 extern int read_host_config(conn_list_t *);
+extern void destroy_conn_list(void);
+extern void prune_conn_list(void);
 
 #endif /* __TINC_CONNLIST_H__ */
index 40acfbb281507dceaf79ecdd82248a881ec7b6ca..aeeec1be63be18985aa9cde7302b89b5478d4345 100644 (file)
@@ -17,7 +17,7 @@
     along with this program; if not, write to the Free Software
     Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
 
-    $Id: protocol.c,v 1.28.4.53 2000/10/29 22:55:14 guus Exp $
+    $Id: protocol.c,v 1.28.4.54 2000/11/03 22:35:11 zarq Exp $
 */
 
 #include "config.h"
@@ -174,7 +174,7 @@ cp
 int id_h(conn_list_t *cl)
 {
   conn_list_t *old;
-  config_t *cfg;
+  config_t const *cfg;
 cp
   if(sscanf(cl->buffer, "%*d %as %d %lx %hd", &cl->name, &cl->protocol_version, &cl->options, &cl->port) != 4)
     {
@@ -803,6 +803,7 @@ int add_host_h(conn_list_t *cl)
 {
   conn_list_t *old, *new;
   conn_list_t *p;
+
 cp
   new = new_conn_list();
 
index 91c0cfba4ec8a15c01f8e4f1b810cc04bf5554f7..82e3f9030d515168ac8a763fbfaa5e1405218030 100644 (file)
@@ -17,7 +17,7 @@
     along with this program; if not, write to the Free Software
     Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
 
-    $Id: protocol.h,v 1.5.4.14 2000/10/29 22:55:15 guus Exp $
+    $Id: protocol.h,v 1.5.4.15 2000/11/03 22:35:12 zarq Exp $
 */
 
 #ifndef __TINC_PROTOCOL_H__
@@ -69,5 +69,7 @@ extern int send_ans_key(conn_list_t*, conn_list_t*, char*);
 
 extern int send_tcppacket(conn_list_t *, void *, int);
 extern int notify_others(conn_list_t *, conn_list_t *, int (*function)(conn_list_t*, conn_list_t*));
+extern int receive_request(conn_list_t *);
+extern int check_id(char *);
 
 #endif /* __TINC_PROTOCOL_H__ */
index 1a9a56084d15860ebacc9ae39c68649a4d394917..9fceea8e0fe386b086257d4edc53f0dd34e8dac2 100644 (file)
     along with this program; if not, write to the Free Software
     Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
 
-    $Id: subnet.c,v 1.1.2.8 2000/10/29 00:02:20 guus Exp $
+    $Id: subnet.c,v 1.1.2.9 2000/11/03 22:35:12 zarq Exp $
 */
 
-#include <syslog.h>
-#include <stdio.h>
-
 #include "config.h"
-#include <utils.h>
 
-#include <xalloc.h>
-#include "subnet.h"
-#include "net.h"
+#include <stdio.h>
+#include <syslog.h>
+
 #include "conf.h"
+#include "net.h"
+#include "subnet.h"
 #include "system.h"
 
+#include <utils.h>
+#include <xalloc.h>
+
 /* lists type of subnet */
 
 subnet_t *subnet_list[SUBNET_TYPES] = { NULL };