summaryrefslogtreecommitdiff
path: root/ofproto/ipfix-gen-entities
diff options
context:
space:
mode:
authorRussell Bryant <russell@ovn.org>2016-01-05 14:50:40 -0500
committerRussell Bryant <russell@ovn.org>2016-01-05 18:18:21 -0500
commiteda26d40ae086539e7de3770818f80580fc231b3 (patch)
tree2e4531b7516b299403567c72108151980bba7bfd /ofproto/ipfix-gen-entities
parentf7f7fcced57438de4ff422712edf6809183b40bc (diff)
downloadopenvswitch-eda26d40ae086539e7de3770818f80580fc231b3.tar.gz
python: Resolve some indentation warnings.
This patch resolves the following warnings from flake8: E111 indentation is not a multiple of four E112 expected an indented block E113 unexpected indentation It's critical to have correct indentation in Python code, so it seemed worth enabling these warnings. Signed-off-by: Russell Bryant <russell@ovn.org> Acked-by: Ben Pfaff <blp@ovn.org>
Diffstat (limited to 'ofproto/ipfix-gen-entities')
-rwxr-xr-xofproto/ipfix-gen-entities47
1 files changed, 21 insertions, 26 deletions
diff --git a/ofproto/ipfix-gen-entities b/ofproto/ipfix-gen-entities
index 6fd76b117..11d2aaf9a 100755
--- a/ofproto/ipfix-gen-entities
+++ b/ofproto/ipfix-gen-entities
@@ -111,32 +111,27 @@ The following options are also available:
sys.exit(0)
if __name__ == '__main__':
-# try:
- try:
- options, args = getopt.gnu_getopt(sys.argv[1:], 'hV',
- ['help', 'version'])
- except getopt.GetoptError, geo:
- sys.stderr.write('%s: %s\n' % (sys.argv[0], geo.msg))
- sys.exit(1)
-
- for key, value in options:
- if key in ['-h', '--help']:
- usage()
- elif key in ['-V', '--version']:
- print 'ipfix-gen-entities (Open vSwitch)'
- else:
- sys.exit(0)
-
- if len(args) != 1:
- sys.stderr.write('%s: exactly 1 non-option arguments required '
- '(use --help for help)\n' % sys.argv[0])
- sys.exit(1)
-
- print_ipfix_entity_macros(args[0])
-
-# except Exception, e:
-# sys.stderr.write('%s: %s\n' % (sys.argv[0], e))
-# sys.exit(1)
+ try:
+ options, args = getopt.gnu_getopt(sys.argv[1:], 'hV',
+ ['help', 'version'])
+ except getopt.GetoptError, geo:
+ sys.stderr.write('%s: %s\n' % (sys.argv[0], geo.msg))
+ sys.exit(1)
+
+ for key, value in options:
+ if key in ['-h', '--help']:
+ usage()
+ elif key in ['-V', '--version']:
+ print 'ipfix-gen-entities (Open vSwitch)'
+ else:
+ sys.exit(0)
+
+ if len(args) != 1:
+ sys.stderr.write('%s: exactly 1 non-option arguments required '
+ '(use --help for help)\n' % sys.argv[0])
+ sys.exit(1)
+
+ print_ipfix_entity_macros(args[0])
# Local variables:
# mode: python