From 41416987e07af0d5b88af580fc3428d20ab69f5e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bj=C3=B6rn=20B=2E=20Brandenburg?= Date: Mon, 24 May 2010 23:22:39 -0400 Subject: plot.py: don't crash on non-existant files --- plot.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'plot.py') diff --git a/plot.py b/plot.py index 3317f54..e649025 100755 --- a/plot.py +++ b/plot.py @@ -328,7 +328,10 @@ class SchedPlotter(defapp.App): self.err("Warning: '%s' doesn't look like a CSV file." % bname) conf = decode(name) - tmpfile = get_data_tmpfile(datafile) + try: + tmpfile = get_data_tmpfile(datafile) + except IOError: + tmpfile = None if tmpfile: if 'spec' in conf: self.plot_spec(tmpfile.name, name, conf) -- cgit v1.2.2