diff options
author | Aaron Bentley <abentley@panoramicfeedback.com> | 2005-03-24 16:40:49 +0000 |
---|---|---|
committer | Aaron Bentley <abentley@panoramicfeedback.com> | 2005-03-24 16:40:49 +0000 |
commit | 4f1f8840a9c842efd09e7516e09f47f8e44ed844 (patch) | |
tree | 419f13136224b5965793510e210f99d4e138aa5b /libbe | |
parent | 0e7c96a2fb5866f42c2c2ae7bccf47ae21f3b025 (diff) | |
download | bugseverywhere-4f1f8840a9c842efd09e7516e09f47f8e44ed844.tar.gz |
Made get_editor_string use contents and mtime to check for changes
Diffstat (limited to 'libbe')
-rw-r--r-- | libbe/utility.py | 3 |
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() |