aboutsummaryrefslogtreecommitdiffstats
path: root/gpxe/src/usr/route.c
diff options
context:
space:
mode:
Diffstat (limited to 'gpxe/src/usr/route.c')
-rw-r--r--gpxe/src/usr/route.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/gpxe/src/usr/route.c b/gpxe/src/usr/route.c
index f3a49f46..18757419 100644
--- a/gpxe/src/usr/route.c
+++ b/gpxe/src/usr/route.c
@@ -16,6 +16,8 @@
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*/
+FILE_LICENCE ( GPL2_OR_LATER );
+
#include <stdio.h>
#include <gpxe/netdevice.h>
#include <gpxe/ip.h>
@@ -34,7 +36,7 @@ void route ( void ) {
printf ( "%s: %s/", miniroute->netdev->name,
inet_ntoa ( miniroute->address ) );
printf ( "%s", inet_ntoa ( miniroute->netmask ) );
- if ( miniroute->gateway.s_addr != INADDR_NONE )
+ if ( miniroute->gateway.s_addr )
printf ( " gw %s", inet_ntoa ( miniroute->gateway ) );
if ( ! ( miniroute->netdev->state & NETDEV_OPEN ) )
printf ( " (inaccessible)" );