fix #1399 trailing whitespace causes bogus handle

svn: r9423
This commit is contained in:
James G Sack 2007-11-28 22:58:33 +00:00
parent b775d17dda
commit 004024a2b3
2 changed files with 7 additions and 1 deletions

View File

@ -1,3 +1,8 @@
2007-11-28 Jim Sack <jgsack@san.rr.com>
* src/GrampsDb/_ReadGedcom.py : #1399 remove trail whitespace (readahead)
fixes discarded reference due to bogus handles that get created
when the reference looks like "@REF_ID@ " (note space after)
2007-11-26 Jim Sack <jgsack@san.rr.com>
* src/plugins/ReadPkg.py : reverted previous change
better to leave it broken than to risk worse

View File

@ -451,6 +451,7 @@ class Reader:
while len(self.current_list) < 5:
old_line = self.f.readline()
self.index += 1
# space ensures no trailing space at end-of-line
line = old_line.strip(' \r\n')
if line == "" and line != old_line:
continue