Commit 634e3e3
committed
Fix: Avoid iteration errors caused by None when reading Nihon Kohden .LOG files
This is a follow-up to #13251. In #13251, some additional checks were added to
`_read_event_log_block` (including a version check), which could cause
`_read_event_log_block` to return `None`, leading to iteration errors.
This change avoids that issue by returning an empty array instead of `None` when
reading fails. In addition, when the version does not match, a warning is now
issued instead of returning `None`.1 parent db75c70 commit 634e3e3
2 files changed
Lines changed: 6 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
289 | 289 | | |
290 | 290 | | |
291 | 291 | | |
| 292 | + | |
| 293 | + | |
292 | 294 | | |
293 | 295 | | |
294 | 296 | | |
295 | | - | |
| 297 | + | |
296 | 298 | | |
297 | 299 | | |
298 | 300 | | |
299 | 301 | | |
300 | 302 | | |
301 | | - | |
| 303 | + | |
302 | 304 | | |
303 | 305 | | |
304 | 306 | | |
305 | 307 | | |
306 | | - | |
| 308 | + | |
307 | 309 | | |
308 | 310 | | |
309 | 311 | | |
| |||
0 commit comments