wido commented on a change in pull request #2791: router: Fixes #2789 fix 
proper mark based packet routing across interfaces
URL: https://github.com/apache/cloudstack/pull/2791#discussion_r207854823
 
 

 ##########
 File path: systemvm/debian/opt/cloud/bin/cs/CsNetfilter.py
 ##########
 @@ -189,7 +189,8 @@ def compare(self, list):
     def add_chain(self, rule):
         """ Add the given chain if it is not already present """
         if not self.has_chain(rule.get_table(), rule.get_chain()):
-            CsHelper.execute("iptables -t %s -N %s" % (rule.get_table(), 
rule.get_chain()))
+            if rule.get_chain() != "":
 
 Review comment:
   I would use:
   
   <pre>
   if rule.get_chain():
   </pre>
   
   This would check for None and empty strings in Python

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to