61 lines
1.9 KiB
Diff
61 lines
1.9 KiB
Diff
|
|
From c8fdd609e905bb2c472758ef6e324cbb43958b9d Mon Sep 17 00:00:00 2001
|
||
|
|
From: sunsuwan <sunsuwan3@huawei.com>
|
||
|
|
Date: Tue, 14 Jun 2022 09:45:56 +0800
|
||
|
|
Subject: [PATCH] fix ebt_print_error for prints null
|
||
|
|
|
||
|
|
---
|
||
|
|
ebtablesd.c | 10 +++++-----
|
||
|
|
1 file changed, 5 insertions(+), 5 deletions(-)
|
||
|
|
|
||
|
|
diff --git a/ebtablesd.c b/ebtablesd.c
|
||
|
|
index 02d51fa..930fc66 100644
|
||
|
|
--- a/ebtablesd.c
|
||
|
|
+++ b/ebtablesd.c
|
||
|
|
@@ -194,7 +194,7 @@ continue_read:
|
||
|
|
}
|
||
|
|
if (!(replace[i].flags & OPT_KERNELDATA)) {
|
||
|
|
ebt_print_error("ebtablesd: table %s has not "
|
||
|
|
- "been opened");
|
||
|
|
+ "been opened", argv[2]);
|
||
|
|
goto write_msg;
|
||
|
|
}
|
||
|
|
ebt_cleanup_replace(&replace[i]);
|
||
|
|
@@ -219,7 +219,7 @@ continue_read:
|
||
|
|
if (replace[i].flags & OPT_KERNELDATA) {
|
||
|
|
ebt_print_error("ebtablesd: table %s needs to "
|
||
|
|
"be freed before it can be "
|
||
|
|
- "opened");
|
||
|
|
+ "opened", argv[2]);
|
||
|
|
goto write_msg;
|
||
|
|
}
|
||
|
|
if (!ebt_get_kernel_table(&replace[i], 0)) {
|
||
|
|
@@ -248,7 +248,7 @@ continue_read:
|
||
|
|
if (replace[i].flags & OPT_KERNELDATA) {
|
||
|
|
ebt_print_error("ebtablesd: table %s needs to "
|
||
|
|
"be freed before it can be "
|
||
|
|
- "opened");
|
||
|
|
+ "opened", argv[2]);
|
||
|
|
goto write_msg;
|
||
|
|
}
|
||
|
|
tmp.filename = (char *)malloc(strlen(argv[3]) + 1);
|
||
|
|
@@ -296,7 +296,7 @@ continue_read:
|
||
|
|
}
|
||
|
|
if (!(replace[i].flags & OPT_KERNELDATA)) {
|
||
|
|
ebt_print_error("ebtablesd: table %s has not "
|
||
|
|
- "been opened");
|
||
|
|
+ "been opened", argv[2]);
|
||
|
|
goto write_msg;
|
||
|
|
}
|
||
|
|
/* The counters from the kernel are useless if we
|
||
|
|
@@ -324,7 +324,7 @@ continue_read:
|
||
|
|
}
|
||
|
|
if (!(replace[i].flags & OPT_KERNELDATA)) {
|
||
|
|
ebt_print_error("ebtablesd: table %s has not "
|
||
|
|
- "been opened");
|
||
|
|
+ "been opened", argv[2]);
|
||
|
|
goto write_msg;
|
||
|
|
}
|
||
|
|
replace[i].filename = (char *)malloc(strlen(argv[3]) + 1);
|
||
|
|
--
|
||
|
|
2.33.0
|