Commit 21f5f8f
authored
Fix parsing of server DateTime (#1499)
std::get_time does not claim support of time zones in the string
parameter, and seems to be subject of locale set on the system. An
example is a following result on linux:
ParseTime(Thu, 1 Jan 1970 0:00:00 GMT)=-2209075200
::strptime is also a subject to the time zones of locale, but it also
claim support for parsing a time zone from the passed string. Thus,
additional logic incorporated to offset parsed DataTime to the local
timezone.
Relates-To: IOTSDK-24021
Signed-off-by: Mykhailo Diachenko <[email protected]>1 parent e343dc1 commit 21f5f8f
File tree
1 file changed
+29
-4
lines changed- olp-cpp-sdk-authentication/src
1 file changed
+29
-4
lines changedLines changed: 29 additions & 4 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
32 | 32 | | |
33 | 33 | | |
34 | 34 | | |
| 35 | + | |
35 | 36 | | |
36 | 37 | | |
37 | 38 | | |
| |||
55 | 56 | | |
56 | 57 | | |
57 | 58 | | |
| 59 | + | |
58 | 60 | | |
59 | 61 | | |
60 | 62 | | |
| |||
95 | 97 | | |
96 | 98 | | |
97 | 99 | | |
98 | | - | |
99 | | - | |
100 | | - | |
101 | | - | |
| 100 | + | |
| 101 | + | |
102 | 102 | | |
103 | 103 | | |
104 | 104 | | |
| 105 | + | |
| 106 | + | |
| 107 | + | |
| 108 | + | |
| 109 | + | |
| 110 | + | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
| 114 | + | |
| 115 | + | |
| 116 | + | |
105 | 117 | | |
106 | 118 | | |
107 | 119 | | |
| 120 | + | |
| 121 | + | |
| 122 | + | |
| 123 | + | |
| 124 | + | |
| 125 | + | |
| 126 | + | |
| 127 | + | |
| 128 | + | |
| 129 | + | |
| 130 | + | |
| 131 | + | |
| 132 | + | |
108 | 133 | | |
109 | 134 | | |
110 | 135 | | |
| |||
0 commit comments