mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
Parser: set timestamp to zero if parsing failed
When parsing of a timestamp failed (shouldn't happen) set the timestamp to zero. This should give less unpredictable results and silence a compiler warning. Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
This commit is contained in:
parent
794066b236
commit
80f123ce2a
1 changed files with 1 additions and 0 deletions
|
@ -343,6 +343,7 @@ static void sampletime(char *buffer, duration_t *time)
|
|||
time->seconds = (hr * 60 + min) * 60 + sec;
|
||||
break;
|
||||
default:
|
||||
time->seconds = 0;
|
||||
printf("Strange sample time reading %s\n", buffer);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue