Mercurial > ecos
diff packages/net/common/current/src/bootp_support.c @ 3016:9306ff8edcbf
* src/bootp_support.c (show_bootp): Fixed output for some fields.
* src/dhcp_prot.c (do_dhcp): Convert bp_secs field to network byte
order. Inspired by Kelvin Lawson. [ Bugzilla 1001170 ]
| author | sergeig |
|---|---|
| date | Fri, 11 Mar 2011 20:00:19 +0000 |
| parents | 74dbf4c3f2e1 |
| children | 24461b5331ea |
line wrap: on
line diff
--- a/packages/net/common/current/src/bootp_support.c +++ b/packages/net/common/current/src/bootp_support.c @@ -274,8 +274,8 @@ show_bootp(const char *intf, struct boot diag_printf(" hlen: %d\n", bp->bp_hlen ); diag_printf(" hops: %d\n", bp->bp_hops ); diag_printf(" xid: 0x%x\n", bp->bp_xid ); - diag_printf(" secs: %d\n", bp->bp_secs ); - diag_printf(" flags: 0x%x\n", bp->bp_flags ); + diag_printf(" secs: %d\n", ntohs(bp->bp_secs) ); + diag_printf(" flags: 0x%x\n", ntohs(bp->bp_flags) ); diag_printf(" hw_addr: "); for (i = 0; i < bp->bp_hlen; i++) { diag_printf("%02x", bp->bp_chaddr[i]);
