diff options
author | Jack Jansen <jack.jansen@cwi.nl> | 1995-08-14 12:41:20 (GMT) |
---|---|---|
committer | Jack Jansen <jack.jansen@cwi.nl> | 1995-08-14 12:41:20 (GMT) |
commit | 479c1b300871f297b716b25c2cd9494d51ace0c8 (patch) | |
tree | 62fc0fd5bb120643c790ae92b15dcfe3951ec57b /Lib | |
parent | 7a58336511b8c405e01bcda0b886b19c2947189a (diff) | |
download | cpython-479c1b300871f297b716b25c2cd9494d51ace0c8.zip cpython-479c1b300871f297b716b25c2cd9494d51ace0c8.tar.gz cpython-479c1b300871f297b716b25c2cd9494d51ace0c8.tar.bz2 |
Put debug output inside 'if DEBUG'.
Diffstat (limited to 'Lib')
-rw-r--r-- | Lib/binhex.py | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/Lib/binhex.py b/Lib/binhex.py index ac7dcfc..8cb34d3 100644 --- a/Lib/binhex.py +++ b/Lib/binhex.py @@ -26,10 +26,10 @@ import struct import string import binascii -DEBUG=1 - -testf = open('@xx', 'w') # XXXX - +DEBUG=0 +if DEBUG: + testf=open('@binhex.dbg.out', 'w') + Error = 'binhex.Error' # States (what have we written) @@ -144,7 +144,8 @@ class _Rlecoderengine: self.data = '' def write(self, data): - testf.write(data) # XXXX + if DEBUG: + testf.write(data) # XXXX self.data = self.data + data if len(self.data) < REASONABLY_LARGE: return @@ -469,7 +470,7 @@ def hexbin(inp, out): def _test(): if os.name == 'mac': - fss, ok = macfs.StandardGetFile() + fss, ok = macfs.PromptGetFile('File to convert:') if not ok: sys.exit(0) fname = fss.as_pathname() |