Commit 1f207d8b authored by Mario Hock's avatar Mario Hock

Fix: cnl_plot crashed when no comment was given

parent 6fe3dcf0
......@@ -292,8 +292,9 @@ if __name__ == "__main__":
## Plot with matplotlib.
## Draw comment on the figure (use absolute positioning).
if ( not args.no_comment ):
t = matplotlib.text.Text(10,10, "Comment: " + cnl_file.get_comment(), figure=fig)
comment = cnl_file.get_comment()
if ( comment and not args.no_comment ):
t = matplotlib.text.Text(10,10, "Comment: " + comment, figure=fig)
fig.texts.append(t)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment