Browse Source

Rename unwieldy function

tags/v0.9.3
Michael Brown 18 years ago
parent
commit
30d9bcdc6e
1 changed files with 4 additions and 4 deletions
  1. 4
    4
      src/net/udp/dhcp.c

+ 4
- 4
src/net/udp/dhcp.c View File

64
  * @v msgtype		DHCP message type
64
  * @v msgtype		DHCP message type
65
  * @ret string		DHCP mesasge type name
65
  * @ret string		DHCP mesasge type name
66
  */
66
  */
67
-static inline const char * dhcp_message_type_name ( unsigned int msgtype ) {
67
+static inline const char * dhcp_msgtype_name ( unsigned int msgtype ) {
68
 	switch ( msgtype ) {
68
 	switch ( msgtype ) {
69
 	case 0:			return "BOOTP"; /* Non-DHCP packet */
69
 	case 0:			return "BOOTP"; /* Non-DHCP packet */
70
 	case DHCPDISCOVER:	return "DHCPDISCOVER";
70
 	case DHCPDISCOVER:	return "DHCPDISCOVER";
457
 	struct dhcp_packet dhcppkt;
457
 	struct dhcp_packet dhcppkt;
458
 	int rc;
458
 	int rc;
459
 	
459
 	
460
-	DBG ( "Transmitting %s\n", dhcp_message_type_name ( dhcp->state ) );
460
+	DBG ( "Transmitting %s\n", dhcp_msgtype_name ( dhcp->state ) );
461
 
461
 
462
 	assert ( ( dhcp->state == DHCPDISCOVER ) ||
462
 	assert ( ( dhcp->state == DHCPDISCOVER ) ||
463
 		 ( dhcp->state == DHCPREQUEST ) );
463
 		 ( dhcp->state == DHCPREQUEST ) );
512
 	}
512
 	}
513
 
513
 
514
 	DBG ( "Received %s\n",
514
 	DBG ( "Received %s\n",
515
-	      dhcp_message_type_name ( find_dhcp_num_option ( options,
516
-						       DHCP_MESSAGE_TYPE ) ) );
515
+	      dhcp_msgtype_name ( find_dhcp_num_option ( options,
516
+							 DHCP_MESSAGE_TYPE )));
517
 
517
 
518
 	/* Proof of concept: just dump out the parsed options */
518
 	/* Proof of concept: just dump out the parsed options */
519
 	hex_dump ( options->data, options->len );
519
 	hex_dump ( options->data, options->len );

Loading…
Cancel
Save