lines:
if (sscanf(formattedTime.c_str(), "%02u%02u%02u%03i%02u", &hours, &minutes, &seconds, &tzHours, &tzMinutes) == 5)
and
if (sscanf(formattedTime.c_str() + pos - 1, "%03i%*c%02u", &tzHours, &tzMinutes) == 2)
according to manuals:
%i: Defaults to base 10 integers. Data starting with 0 is read as base 8.
Data starting with 0x or 0X is read as base 16.
so, setISOFormattedTime can't recognize time zones <= -0800 and >= +0800
bug in OFTime::setISOFormattedTime
Moderator: Moderator Team
-
- DCMTK Developer
- Posts: 2506
- Joined: Tue, 2011-05-03, 14:38
- Location: Oldenburg, Germany
- Contact:
Re: bug in OFTime::setISOFormattedTime
Thank you for the report. So, "%i" should be replaced by "%d", right?
Will be fixed with Commit bc268ae.
Code: Select all
d Matches an optionally signed decimal integer; the next pointer must be a pointer to int.
Who is online
Users browsing this forum: No registered users and 1 guest