Browse Source

Be less fussy about broken IGC files.

master
Tom Payne 13 years ago
parent
commit
fb6748bc56
  1. 5
      igc2kmz/igc.py

5
igc2kmz/igc.py

@ -87,7 +87,10 @@ class BRecord(Record):
if not m:
raise SyntaxError, line
for key, value in igc.i.items():
setattr(result, key, int(line[value]))
try:
setattr(result, key, int(line[value]))
except ValueError:
setattr(result, key, None)
time = datetime.time(*map(int, m.group(1, 2, 3)))
result.dt = datetime.datetime.combine(igc.hfdterecord.date, time)
if igc.b and result.dt < igc.b[-1].dt:

Loading…
Cancel
Save