forked frompostgres/postgres
- Notifications
You must be signed in to change notification settings - Fork6
Commit6412f3e
committed
Reject out-of-range numeric timezone specifications.
In commit631dc39, we started to handlesimple numeric timezone offsets via the zic library instead of the oldCTimeZone/HasCTZSet kluge. However, we overlooked the fact that the ziccode will reject UTC offsets exceeding a week (which seems a bit arbitrary,but not because it's too tight ...). This led to possibly settingsession_timezone to NULL, which results in crashes in most timezone-relatedoperations as of 9.4, and crashes in a small number of places even beforethat. So check for NULL return from pg_tzset_offset() and report anappropriate error message. Per bug #11014 from Duncan Gillis.Back-patch to all supported branches, like the previous patch.(Unfortunately, as of today that no longer includes 8.4.)1 parent212825f commit6412f3e
2 files changed
+10
-0
lines changedLines changed: 7 additions & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
349 | 349 |
| |
350 | 350 |
| |
351 | 351 |
| |
| 352 | + | |
| 353 | + | |
| 354 | + | |
| 355 | + | |
| 356 | + | |
| 357 | + | |
| 358 | + | |
352 | 359 |
| |
353 | 360 |
| |
354 | 361 |
| |
|
Lines changed: 3 additions & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
296 | 296 |
| |
297 | 297 |
| |
298 | 298 |
| |
| 299 | + | |
| 300 | + | |
| 301 | + | |
299 | 302 |
| |
300 | 303 |
| |
301 | 304 |
| |
|
0 commit comments
Comments
(0)