aboutsummaryrefslogtreecommitdiffstats
path: root/libbe
diff options
context:
space:
mode:
authorAaron Bentley <abentley@panoramicfeedback.com>2005-03-24 16:40:49 +0000
committerAaron Bentley <abentley@panoramicfeedback.com>2005-03-24 16:40:49 +0000
commit4f1f8840a9c842efd09e7516e09f47f8e44ed844 (patch)
tree419f13136224b5965793510e210f99d4e138aa5b /libbe
parent0e7c96a2fb5866f42c2c2ae7bccf47ae21f3b025 (diff)
downloadbugseverywhere-4f1f8840a9c842efd09e7516e09f47f8e44ed844.tar.gz
Made get_editor_string use contents and mtime to check for changes
Diffstat (limited to 'libbe')
-rw-r--r--libbe/utility.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/libbe/utility.py b/libbe/utility.py
index de5d2c5..a392538 100644
--- a/libbe/utility.py
+++ b/libbe/utility.py
@@ -91,7 +91,8 @@ def editor_string():
os.close(fhandle)
oldmtime = os.path.getmtime(fname)
os.system("%s %s" % (editor, fname))
- if oldmtime == os.path.getmtime(fname):
+ if oldmtime == os.path.getmtime(fname) and\
+ file(fname, "rb").read() == "":
output = None
else:
output = file(fname, "rb").read()