Blob Blame History Raw
commit db98f3b50301027cc822c87ffdc1a75671e9486b
Author: Thomas Woerner <twoerner@redhat.com>
Date:   Mon Aug 15 12:46:59 2016 +0200

    firewall.core.logger: Warnings should be printed to stderr per default

diff --git a/src/firewall/core/logger.py b/src/firewall/core/logger.py
index c068e9a..3734762 100644
--- a/src/firewall/core/logger.py
+++ b/src/firewall/core/logger.py
@@ -281,9 +281,10 @@ class Logger(object):
         self.setDebugLogLevel(self.NO_DEBUG)
         self.setFormat("%(label)s%(message)s")
         self.setDateFormat("%d %b %Y %H:%M:%S")
-        self.setInfoLogging("*", self.stderr, [ self.FATAL, self.ERROR ])
+        self.setInfoLogging("*", self.stderr, [ self.FATAL, self.ERROR,
+                                                self.WARNING ])
         self.setInfoLogging("*", self.stdout,
-                        [ i for i in range(self.WARNING, self.INFO_MAX+1) ])
+                            [ i for i in range(self.INFO1, self.INFO_MAX+1) ])
         self.setDebugLogging("*", self.stdout,
                              [ i for i in range(1, self.DEBUG_MAX+1) ])
 

commit c51c0ef4dc7e440b0bc2d846f9810aa366699697
Author: Thomas Woerner <twoerner@redhat.com>
Date:   Mon Aug 15 12:47:53 2016 +0200

    test-suite: Ignore stderr to get default zone also for missing firewalld.conf
    
    With latest changes the message about missing firewalld.conf is printed to
    stderr. This message on stderr needs to be ignored to be able to get the
    fallback default zone setting.

diff --git a/src/tests/firewall-cmd_test.sh b/src/tests/firewall-cmd_test.sh
index 59ea81a..bc06ce0 100755
--- a/src/tests/firewall-cmd_test.sh
+++ b/src/tests/firewall-cmd_test.sh
@@ -170,7 +170,7 @@ assert_bad  "--query-panic"
 #assert_good "--lockdown-off"
 #assert_bad  "--query-lockdown"
 
-default_zone=$(${path}firewall-cmd --get-default-zone)
+default_zone=$(${path}firewall-cmd --get-default-zone 2>/dev/null)
 zone="home"
 assert_good_notempty "--get-default-zone"
 assert_good          "--set-default-zone=${zone}"
diff --git a/src/tests/firewall-offline-cmd_test.sh b/src/tests/firewall-offline-cmd_test.sh
index 00f9a01..ebbdfad 100755
--- a/src/tests/firewall-offline-cmd_test.sh
+++ b/src/tests/firewall-offline-cmd_test.sh
@@ -236,7 +236,7 @@ test_lokkit_opts
 # disable dns again for later tests
 assert_good --remove-service=${service1}
 
-default_zone=$(${path}firewall-offline-cmd --get-default-zone)
+default_zone=$(${path}firewall-offline-cmd --get-default-zone 2>/dev/null)
 zone="home"
 assert_good_notempty "--get-default-zone"
 assert_good          "--set-default-zone=${zone}"