From 3d2eed555d5080c94dea16af4991fc4b9d7f4cb1 Mon Sep 17 00:00:00 2001 From: Darshan Kowlaser <59197203+dkay-zaxxx@users.noreply.github.com> Date: Mon, 27 Nov 2023 20:17:36 +0200 Subject: [PATCH] fixed - mikrotik routerosv7 output (#103) * fixed - mikrotik routerosv7 output * fixed - mikrotik routerosv7 output --------- Co-authored-by: dkayza-xxx --- printer.c | 2 +- tests/reference/routeros7--4.txt | 4 ++-- tests/reference/routeros7--6.txt | 4 ++-- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/printer.c b/printer.c index d97cb71..7c62ee8 100644 --- a/printer.c +++ b/printer.c @@ -1870,7 +1870,7 @@ bgpq4_print_k7prefix(struct sx_radix_node *n, void *ff) prefix, n->aggregateLow, n->aggregateHi); else fprintf(f,"/routing filter rule add chain=\"" - "%s-%s\" rule=\"if (dst=%s) {accept}\"\n", + "%s-%s\" rule=\"if (dst==%s) {accept}\"\n", bname ? bname : "NN", n->prefix->family == AF_INET ? "V4" : "V6", prefix); diff --git a/tests/reference/routeros7--4.txt b/tests/reference/routeros7--4.txt index 003bd6d..2eb4e99 100644 --- a/tests/reference/routeros7--4.txt +++ b/tests/reference/routeros7--4.txt @@ -1,2 +1,2 @@ -/routing filter rule add chain="NN-V4" rule="if (dst=192.31.196.0/24) {accept}" -/routing filter rule add chain="NN-V4" rule="if (dst=192.175.48.0/24) {accept}" +/routing filter rule add chain="NN-V4" rule="if (dst==192.31.196.0/24) {accept}" +/routing filter rule add chain="NN-V4" rule="if (dst==192.175.48.0/24) {accept}" diff --git a/tests/reference/routeros7--6.txt b/tests/reference/routeros7--6.txt index 6bac4f5..5a86fb8 100644 --- a/tests/reference/routeros7--6.txt +++ b/tests/reference/routeros7--6.txt @@ -1,2 +1,2 @@ -/routing filter rule add chain="NN-V6" rule="if (dst=2001:4:112::/48) {accept}" -/routing filter rule add chain="NN-V6" rule="if (dst=2620:4f:8000::/48) {accept}" +/routing filter rule add chain="NN-V6" rule="if (dst==2001:4:112::/48) {accept}" +/routing filter rule add chain="NN-V6" rule="if (dst==2620:4f:8000::/48) {accept}"