diff mbox

[nft] linealize: generate unary expression with the appropiate operation

Message ID 1408395612-9791-1-git-send-email-alvaroneay@gmail.com
State Accepted
Delegated to: Pablo Neira
Headers show

Commit Message

Alvaro Neira Aug. 18, 2014, 9 p.m. UTC
If we add a unary expression which the operation is ntoh, we use hton.
This looks like a typo.

Signed-off-by: Alvaro Neira Ayuso <alvaroneay@gmail.com>
---
 src/netlink_linearize.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Pablo Neira Ayuso Aug. 18, 2014, 10:09 p.m. UTC | #1
On Mon, Aug 18, 2014 at 11:00:12PM +0200, Alvaro Neira Ayuso wrote:
> If we add a unary expression which the operation is ntoh, we use hton.
> This looks like a typo.

Applied, thanks.

--
To unsubscribe from this list: send the line "unsubscribe netfilter-devel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
diff mbox

Patch

diff --git a/src/netlink_linearize.c b/src/netlink_linearize.c
index 0e1d87c..3e48e9b 100644
--- a/src/netlink_linearize.c
+++ b/src/netlink_linearize.c
@@ -442,7 +442,7 @@  static enum nft_byteorder_ops netlink_gen_unary_op(enum ops op)
 	case OP_HTON:
 		return NFT_BYTEORDER_HTON;
 	case OP_NTOH:
-		return NFT_BYTEORDER_HTON;
+		return NFT_BYTEORDER_NTOH;
 	default:
 		BUG("invalid unary operation %u\n", op);
 	}