1 Index: pepperspot-0.4/src/cmdline.c
2 ===================================================================
3 --- pepperspot-0.4.orig/src/cmdline.c 2010-01-16 14:25:11.000000000 +0200
4 +++ pepperspot-0.4/src/cmdline.c 2012-05-28 16:21:56.000000000 +0300
9 -cmdline_parser_internal (int argc, char * const *argv, struct gengetopt_args_info *args_info, int override, int initialize, int check_required, const char *additional_error)
10 +cmdline_parser_internal (int argc, char * const *argv, struct gengetopt_args_info *args_info, int override, int initialize, int check_required __attribute__((__unused__)), const char *additional_error)
12 int c; /* Character of the parsed option. */
13 char *multi_token, *multi_next; /* for multiple options */
14 Index: pepperspot-0.4/src/ippool.c
15 ===================================================================
16 --- pepperspot-0.4.orig/src/ippool.c 2010-01-20 09:42:01.000000000 +0200
17 +++ pepperspot-0.4/src/ippool.c 2012-05-28 16:22:57.000000000 +0300
20 /* Get IP address and mask */
21 int ippool_aton(struct in_addr *addr, struct in_addr *mask,
22 - char *pool, int number)
23 + char *pool, int number __attribute__((__unused__)))
25 /* Parse only first instance of network for now */
26 /* Eventually "number" will indicate the token which we want to parse */
27 Index: pepperspot-0.4/src/pepper.c
28 ===================================================================
29 --- pepperspot-0.4.orig/src/pepper.c 2012-05-28 16:09:54.000000000 +0300
30 +++ pepperspot-0.4/src/pepper.c 2012-05-28 16:10:39.000000000 +0300
33 * \author Sebastien Vincent
35 -static int cb_tun6_ind(struct tun6_t* tun_obj, void* pack, unsigned len)
36 +static int cb_tun6_ind(struct tun6_t* tun_obj __attribute__((__unused__)), void* pack, unsigned len)
38 struct ippoolm_t* ipm = NULL;
41 * \param len data length
44 -int cb_tun_ind(struct tun_t *tun_obj, void *pack, unsigned len)
45 +int cb_tun_ind(struct tun_t *tun_obj __attribute__((__unused__)), void *pack, unsigned len)
47 struct ippoolm_t *ipm = NULL;
50 * \param conn redir connection that we will filled up up-to-date value
51 * \return 0 if success, -1 otherwise
53 -static int cb_redir_getstate(struct redir_t *redir_obj, struct in_addr *addr,
54 +static int cb_redir_getstate(struct redir_t *redir_obj __attribute__((__unused__)), struct in_addr *addr,
55 struct redir_conn_t *conn)
57 struct ippoolm_t *ipm = NULL;
59 * \param conn redir connection that we will filled up up-to-date value
60 * \return 0 if success, -1 otherwise
62 -static int cb_redir_getstatev6(struct redir_t* redir_obj, struct in6_addr* addr, struct redir_conn_t* conn)
63 +static int cb_redir_getstatev6(struct redir_t* redir_obj __attribute__((__unused__)), struct in6_addr* addr, struct redir_conn_t* conn)
65 struct ippoolm_t *ipm = NULL;
66 struct app_conn_t *appconn = NULL;
68 * \param pack_req packet for request
69 * \return 0 if success, -1 otherwise
71 -int radius_conf(struct radius_t *radius_obj,
72 +int radius_conf(struct radius_t *radius_obj __attribute__((__unused__)),
73 struct radius_packet_t *pack,
74 - struct radius_packet_t *pack_req)
75 + struct radius_packet_t *pack_req __attribute__((__unused__)))
77 struct radius_attr_t *attr = NULL;
79 Index: pepperspot-0.4/src/tun.c
80 ===================================================================
81 --- pepperspot-0.4.orig/src/tun.c 2010-01-27 14:05:01.000000000 +0200
82 +++ pepperspot-0.4/src/tun.c 2012-05-28 16:20:10.000000000 +0300
84 struct sockaddr_nl local;
88 + int status __attribute__((__unused__)) = 0;
90 struct sockaddr_nl nladdr;
93 * \param delete 1 = delete route, 0 = add route
94 * \return 0 if success, -1 otherwise
96 -static int tun_route(struct tun_t *this,
97 +static int tun_route(struct tun_t *this __attribute__((__unused__)),
99 struct in_addr *gateway,
100 struct in_addr *mask,
101 Index: pepperspot-0.4/src/dhcp.c
102 ===================================================================
103 --- pepperspot-0.4.orig/src/dhcp.c 2012-05-28 15:57:59.000000000 +0300
104 +++ pepperspot-0.4/src/dhcp.c 2012-05-28 16:42:50.000000000 +0300
105 @@ -2111,7 +2111,7 @@
109 -struct timeval* dhcp_timeleft(struct dhcp_t *this, struct timeval *tvp)
110 +struct timeval* dhcp_timeleft(struct dhcp_t *this __attribute__((__unused__)), struct timeval *tvp)
112 /* To avoid unused parameter warning */
114 @@ -2640,7 +2640,7 @@
115 * \return 0 if success, -1 otherwise4
117 static int dhcp_sendOFFER(struct dhcp_conn_t *conn,
118 - struct dhcp_fullpacket_t *pack, int len)
119 + struct dhcp_fullpacket_t *pack, int len __attribute__((__unused__)))
121 struct dhcp_t *this = conn->parent;
122 struct dhcp_fullpacket_t packet;
123 @@ -2762,7 +2762,7 @@
124 * \return 0 if success, -1 otherwise
126 static int dhcp_sendACK(struct dhcp_conn_t *conn,
127 - struct dhcp_fullpacket_t *pack, int len)
128 + struct dhcp_fullpacket_t *pack, int len __attribute__((__unused__)))
130 struct dhcp_t *this = conn->parent;
131 struct dhcp_fullpacket_t packet;
132 @@ -2895,7 +2895,7 @@
133 * \return 0 if success, -1 otherwise
135 static int dhcp_sendNAK(struct dhcp_conn_t *conn,
136 - struct dhcp_fullpacket_t *pack, int len)
137 + struct dhcp_fullpacket_t *pack, int len __attribute__((__unused__)))
139 struct dhcp_t *this = conn->parent;
140 struct dhcp_fullpacket_t packet;
141 @@ -3496,7 +3496,7 @@
144 static int dhcp_sendARP(struct dhcp_conn_t *conn,
145 - struct dhcp_arp_fullpacket_t *pack, int len)
146 + struct dhcp_arp_fullpacket_t *pack, int len __attribute__((__unused__)))
148 struct dhcp_t *this = conn->parent;
149 struct dhcp_arp_fullpacket_t packet;
150 Index: pepperspot-0.4/src/radius.c
151 ===================================================================
152 --- pepperspot-0.4.orig/src/radius.c 2012-05-28 15:57:59.000000000 +0300
153 +++ pepperspot-0.4/src/radius.c 2012-05-28 16:37:47.000000000 +0300
155 * \param secretlen length of secret
158 -static int radius_authresp_authenticator(struct radius_t *this,
159 +static int radius_authresp_authenticator(struct radius_t *this __attribute__((__unused__)),
160 struct radius_packet_t *pack,
162 char *secret, int secretlen)
167 -int radius_addattrv6(struct radius_t *this, struct radius_packet_t *pack,
168 +int radius_addattrv6(struct radius_t *this __attribute__((__unused__)), struct radius_packet_t *pack,
169 uint8_t type, uint32_t vendor_id, uint8_t vendor_type,
170 struct in6_addr value, uint8_t *data, uint16_t dlen)
172 @@ -1124,7 +1124,7 @@
176 -int radius_keydecode(struct radius_t *this, uint8_t *dst, int dstsize,
177 +int radius_keydecode(struct radius_t *this __attribute__((__unused__)), uint8_t *dst, int dstsize,
178 int *dstlen, uint8_t *src, int srclen,
179 uint8_t *authenticator, char *secret, int secretlen)
181 @@ -1346,7 +1346,7 @@
185 -int radius_pwencode(struct radius_t *this, uint8_t *dst, int dstsize,
186 +int radius_pwencode(struct radius_t *this __attribute__((__unused__)), uint8_t *dst, int dstsize,
187 int *dstlen, uint8_t *src, int srclen,
188 uint8_t *authenticator, char *secret, int secretlen)
190 Index: pepperspot-0.4/src/redir.c
191 ===================================================================
192 --- pepperspot-0.4.orig/src/redir.c 2012-05-28 15:57:59.000000000 +0300
193 +++ pepperspot-0.4/src/redir.c 2012-05-28 16:41:17.000000000 +0300
195 * \param dstsize size of dst
196 * \return 0 if success, -1 otherwise
198 -static int redir_getpath(struct redir_t *redir, char *src, char *dst, int dstsize)
199 +static int redir_getpath(struct redir_t *redir __attribute__((__unused__)), char *src, char *dst, int dstsize)
203 @@ -1045,7 +1045,7 @@
205 * \brief Get the url of an HTTP request.
207 -static int redir_geturl(struct redir_t *redir, char *src, char *dst, int dstsize)
208 +static int redir_geturl(struct redir_t *redir __attribute__((__unused__)), char *src, char *dst, int dstsize)
212 @@ -1128,7 +1128,7 @@
213 * \return 0 if found, -1 otherwise (not found, malformed HTTP response)
215 /* TODO: Should be merged with other parsers */
216 -static int redir_getparam(struct redir_t *redir, char *src,
217 +static int redir_getparam(struct redir_t *redir __attribute__((__unused__)), char *src,
219 char *dst, int dstsize)
221 @@ -1362,9 +1362,9 @@
222 * \param cbp pointer for callback
225 -static int redir_cb_radius_auth_conf(struct radius_t *radius,
226 +static int redir_cb_radius_auth_conf(struct radius_t *radius __attribute__((__unused__)),
227 struct radius_packet_t *pack,
228 - struct radius_packet_t *pack_req, void *cbp)
229 + struct radius_packet_t *pack_req __attribute__((__unused__)), void *cbp)
231 struct radius_attr_t *interimattr = NULL;
232 struct radius_attr_t *stateattr = NULL;
233 @@ -1696,7 +1696,7 @@
234 * \param conn redir connection
235 * \return 0 if success, -1 otherwise
237 -static int redir_radius(struct redir_t *redir, struct sockaddr_storage *addr,
238 +static int redir_radius(struct redir_t *redir, struct sockaddr_storage *addr __attribute__((__unused__)),
239 struct redir_conn_t *conn)
241 struct radius_t *radius = NULL; /* Radius client instance */
242 Index: pepperspot-0.4/src/tun6.c
243 ===================================================================
244 --- pepperspot-0.4.orig/src/tun6.c 2009-11-09 17:01:57.000000000 +0200
245 +++ pepperspot-0.4/src/tun6.c 2012-05-28 16:44:07.000000000 +0300
246 @@ -1080,7 +1080,7 @@
250 -int tun6_addroute(struct tun6_t *this, struct in6_addr *dst, struct in6_addr *gateway, uint8_t prefixlen)
251 +int tun6_addroute(struct tun6_t *this __attribute__((__unused__)), struct in6_addr *dst __attribute__((__unused__)), struct in6_addr *gateway __attribute__((__unused__)), uint8_t prefixlen __attribute__((__unused__)))
253 /* TODO : use _iface_route */
255 @@ -1096,7 +1096,7 @@
259 -int tun6_runscript(struct tun6_t *tun, char* script)
260 +int tun6_runscript(struct tun6_t *tun __attribute__((__unused__)), char* script __attribute__((__unused__)))