Browse Source

Warnings purge: src/{crypto,hci,net}

tags/v0.9.3
Marty Connor 17 years ago
parent
commit
c77704cb60

+ 1
- 1
src/crypto/axtls/bigint.c View File

482
 /*
482
 /*
483
  * Perform an integer divide on a bigint.
483
  * Perform an integer divide on a bigint.
484
  */
484
  */
485
-static bigint *bi_int_divide(BI_CTX *ctx, bigint *biR, comp denom)
485
+static bigint *bi_int_divide(__unused BI_CTX *ctx, bigint *biR, comp denom)
486
 {
486
 {
487
     int i = biR->size - 1;
487
     int i = biR->size - 1;
488
     long_comp r = 0;
488
     long_comp r = 0;

+ 5
- 0
src/hci/commands/dhcp_cmd.c View File

16
  * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
16
  * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
17
  */
17
  */
18
 
18
 
19
+#include <stdio.h>
19
 #include <stdint.h>
20
 #include <stdint.h>
20
 #include <stdlib.h>
21
 #include <stdlib.h>
21
 #include <stdio.h>
22
 #include <stdio.h>
23
+#include <errno.h>
24
+#include <stddef.h>
25
+#include <string.h>
26
+#include <assert.h>
22
 #include <getopt.h>
27
 #include <getopt.h>
23
 #include <gpxe/netdevice.h>
28
 #include <gpxe/netdevice.h>
24
 #include <gpxe/command.h>
29
 #include <gpxe/command.h>

+ 1
- 0
src/hci/mucurses/ansi_screen.c View File

1
+#include <stdio.h>
1
 #include <curses.h>
2
 #include <curses.h>
2
 #include <console.h>
3
 #include <console.h>
3
 
4
 

+ 1
- 0
src/hci/readline.c View File

16
  * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
16
  * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
17
  */
17
  */
18
 
18
 
19
+#include <stdio.h>
19
 #include <string.h>
20
 #include <string.h>
20
 #include <stdlib.h>
21
 #include <stdlib.h>
21
 #include <console.h>
22
 #include <console.h>

+ 1
- 0
src/hci/shell_banner.c View File

16
  * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
16
  * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
17
  */
17
  */
18
 
18
 
19
+#include <stdio.h>
19
 #include <console.h>
20
 #include <console.h>
20
 #include <latch.h>
21
 #include <latch.h>
21
 #include <gpxe/shell_banner.h>
22
 #include <gpxe/shell_banner.h>

+ 1
- 0
src/hci/tui/settings_ui.c View File

16
  * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
16
  * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
17
  */
17
  */
18
 
18
 
19
+#include <stdio.h>
19
 #include <stdarg.h>
20
 #include <stdarg.h>
20
 #include <unistd.h>
21
 #include <unistd.h>
21
 #include <string.h>
22
 #include <string.h>

+ 1
- 1
src/include/gpxe/ip6.h View File

24
 #define MIN_IOB_LEN	MAX_HDR_LEN + 100 /* To account for padding by LL */
24
 #define MIN_IOB_LEN	MAX_HDR_LEN + 100 /* To account for padding by LL */
25
 
25
 
26
 #define IP6_EQUAL( in6_addr1, in6_addr2 ) \
26
 #define IP6_EQUAL( in6_addr1, in6_addr2 ) \
27
-        ( strncmp ( ( char* ) &( in6_addr1 ), ( char* ) &( in6_addr2 ),\
27
+        ( memcmp ( ( char* ) &( in6_addr1 ), ( char* ) &( in6_addr2 ),\
28
 	sizeof ( struct in6_addr ) ) == 0 )
28
 	sizeof ( struct in6_addr ) ) == 0 )
29
 
29
 
30
 #define IS_UNSPECIFIED( addr ) \
30
 #define IS_UNSPECIFIED( addr ) \

+ 4
- 4
src/net/ipv6.c View File

204
 	 */
204
 	 */
205
 	next_hop = dest->sin6_addr;
205
 	next_hop = dest->sin6_addr;
206
 	list_for_each_entry ( miniroute, &miniroutes, list ) {
206
 	list_for_each_entry ( miniroute, &miniroutes, list ) {
207
-		if ( ( strncmp ( &ip6hdr->dest, &miniroute->prefix,
207
+		if ( ( memcmp ( &ip6hdr->dest, &miniroute->prefix,
208
 					miniroute->prefix_len ) == 0 ) ||
208
 					miniroute->prefix_len ) == 0 ) ||
209
 		     ( IP6_EQUAL ( miniroute->gateway, ip6_none ) ) ) {
209
 		     ( IP6_EQUAL ( miniroute->gateway, ip6_none ) ) ) {
210
 			netdev = miniroute->netdev;
210
 			netdev = miniroute->netdev;
295
  * This function processes a IPv6 packet
295
  * This function processes a IPv6 packet
296
  */
296
  */
297
 static int ipv6_rx ( struct io_buffer *iobuf,
297
 static int ipv6_rx ( struct io_buffer *iobuf,
298
-		     struct net_device *netdev,
299
-		     const void *ll_source ) {
298
+		     __unused struct net_device *netdev,
299
+		     __unused const void *ll_source ) {
300
 
300
 
301
 	struct ip6_header *ip6hdr = iobuf->data;
301
 	struct ip6_header *ip6hdr = iobuf->data;
302
 	union {
302
 	union {
316
 	ipv6_dump ( ip6hdr );
316
 	ipv6_dump ( ip6hdr );
317
 
317
 
318
 	/* Check header version */
318
 	/* Check header version */
319
-	if ( ip6hdr->ver_traffic_class_flow_label & 0xf0000000 != 0x60000000 ) {
319
+	if ( ( ip6hdr->ver_traffic_class_flow_label & 0xf0000000 ) != 0x60000000 ) {
320
 		DBG ( "Invalid protocol version\n" );
320
 		DBG ( "Invalid protocol version\n" );
321
 		goto drop;
321
 		goto drop;
322
 	}
322
 	}

Loading…
Cancel
Save