Quellcode durchsuchen

Move definition of struct rtpp_node into nathelper.h.

Maxim Sobolev vor 17 Jahren
Ursprung
Commit
bb81565762
2 geänderte Dateien mit 13 neuen und 14 gelöschten Zeilen
  1. 0 14
      modules_s/nathelper/nathelper.c
  2. 13 0
      modules_s/nathelper/nathelper.h

+ 0 - 14
modules_s/nathelper/nathelper.c

@@ -250,7 +250,6 @@ MODULE_VERSION
 #define	CPORT		"22222"
 
 struct rtpp_head;
-struct rtpp_node;
 
 static int nat_uac_test_f(struct sip_msg* msg, char* str1, char* str2);
 static int fix_nated_contact_f(struct sip_msg *, char *, char *);
@@ -326,19 +325,6 @@ struct rtpp_head {
 	struct rtpp_node	*rn_last;
 };
 
-struct rtpp_node {
-	char			*rn_url;	/* unparsed, deletable */
-	int			rn_umode;
-	char			*rn_address;	/* substring of rn_url */
-	int			rn_fd;		/* control fd */
-	int			rn_disabled;	/* found unaccessible? */
-	unsigned		rn_weight;	/* for load balancing */
-	int			rn_recheck_ticks;
-	int			rn_rep_supported;
-	int			rn_ptl_supported;
-	struct rtpp_node	*rn_next;
-};
-
 /* RTP proxy balancing list */
 static struct rtpp_head rtpp_list;
 static int rtpp_node_count = 0;

+ 13 - 0
modules_s/nathelper/nathelper.h

@@ -32,6 +32,19 @@
 #define	STR2IOVEC(sx, ix)	do {(ix).iov_base = (sx).s; (ix).iov_len = (sx).len;} while(0)
 #define SZ2IOVEC(sx, ix)	do {char *_t_p = (ix).iov_base = (sx); (ix).iov_len = strlen(_t_p);} while(0)
 
+struct rtpp_node {
+    char                    *rn_url;        /* unparsed, deletable */
+    int                     rn_umode;
+    char                    *rn_address;    /* substring of rn_url */
+    int                     rn_fd;          /* control fd */
+    int                     rn_disabled;    /* found unaccessible? */
+    unsigned                rn_weight;      /* for load balancing */
+    int                     rn_recheck_ticks;
+    int                     rn_rep_supported;
+    int                     rn_ptl_supported;
+    struct rtpp_node        *rn_next;
+};
+
 /* Parameters from nathelper.c */
 extern struct socket_info* force_socket;