This commit is contained in:
@@ -102,7 +102,7 @@ class NftManager:
|
|||||||
Return parsed JSON (a Python dict/list) for `nft -j list ruleset`.
|
Return parsed JSON (a Python dict/list) for `nft -j list ruleset`.
|
||||||
Handle possible double-encoded outputs by unwrapping.
|
Handle possible double-encoded outputs by unwrapping.
|
||||||
"""
|
"""
|
||||||
rc, out, err = self.json_cmd("list ruleset")
|
rc, out, err = self.cmd("list ruleset -j")
|
||||||
if rc != 0:
|
if rc != 0:
|
||||||
raise NftError(f"nft list ruleset failed (json): {err}")
|
raise NftError(f"nft list ruleset failed (json): {err}")
|
||||||
try:
|
try:
|
||||||
|
|||||||
Reference in New Issue
Block a user