Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/usr.sbin/npf/npfctl npfctl_print_nat: fix the byte-order of ...
details: https://anonhg.NetBSD.org/src/rev/f1b3ffcfa35d
branches: trunk
changeset: 326809:f1b3ffcfa35d
user: rmind <rmind%NetBSD.org@localhost>
date: Wed Feb 19 01:43:16 2014 +0000
description:
npfctl_print_nat: fix the byte-order of the port.
diffstat:
usr.sbin/npf/npfctl/npf_show.c | 6 +++---
1 files changed, 3 insertions(+), 3 deletions(-)
diffs (27 lines):
diff -r 2d7945d2be5a -r f1b3ffcfa35d usr.sbin/npf/npfctl/npf_show.c
--- a/usr.sbin/npf/npfctl/npf_show.c Tue Feb 18 22:05:56 2014 +0000
+++ b/usr.sbin/npf/npfctl/npf_show.c Wed Feb 19 01:43:16 2014 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: npf_show.c,v 1.11 2014/02/12 01:42:50 rmind Exp $ */
+/* $NetBSD: npf_show.c,v 1.12 2014/02/19 01:43:16 rmind Exp $ */
/*-
* Copyright (c) 2013 The NetBSD Foundation, Inc.
@@ -36,7 +36,7 @@
*/
#include <sys/cdefs.h>
-__RCSID("$NetBSD: npf_show.c,v 1.11 2014/02/12 01:42:50 rmind Exp $");
+__RCSID("$NetBSD: npf_show.c,v 1.12 2014/02/19 01:43:16 rmind Exp $");
#include <sys/socket.h>
#include <netinet/in.h>
@@ -390,7 +390,7 @@
seg = npfctl_print_addrmask(alen, &addr, NPF_NO_NETMASK);
if (port) {
char *p;
- easprintf(&p, "%s port %u", seg, port);
+ easprintf(&p, "%s port %u", seg, ntohs(port));
free(seg), seg = p;
}
seg1 = seg2 = "any";
Home |
Main Index |
Thread Index |
Old Index