forked frompostgres/postgres
- Notifications
You must be signed in to change notification settings - Fork6
Commit5e80d35
committed
Avoid dereferencing an undefined pointer in DecodeInterval().
Commite39f990 moved some code up closer to the start ofDecodeInterval(), without noticing that it had been implicitlyrelying on previous checks to reject the case of empty input.Given empty input, we'd now dereference a pointer that hadn't beenset, possibly leading to a core dump. (But if we fail to provokea SIGSEGV, nothing bad happens, and the expected syntax error isthrown a bit later.)Per bug #17788 from Alexander Lakhin. Back-patch to v15 wherethe fault was introduced.Discussion:https://postgr.es/m/17788-dabac9f98f7eafd5@postgresql.org1 parent156c049 commit5e80d35
File tree
3 files changed
+9
-1
lines changed- src
- backend/utils/adt
- test/regress
- expected
- sql
3 files changed
+9
-1
lines changedLines changed: 1 addition & 1 deletion
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
3376 | 3376 |
| |
3377 | 3377 |
| |
3378 | 3378 |
| |
3379 |
| - | |
| 3379 | + | |
3380 | 3380 |
| |
3381 | 3381 |
| |
3382 | 3382 |
| |
|
Lines changed: 5 additions & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
888 | 888 |
| |
889 | 889 |
| |
890 | 890 |
| |
| 891 | + | |
| 892 | + | |
| 893 | + | |
| 894 | + | |
| 895 | + | |
891 | 896 |
| |
892 | 897 |
| |
893 | 898 |
| |
|
Lines changed: 3 additions & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
284 | 284 |
| |
285 | 285 |
| |
286 | 286 |
| |
| 287 | + | |
| 288 | + | |
| 289 | + | |
287 | 290 |
| |
288 | 291 |
| |
289 | 292 |
| |
|
0 commit comments
Comments
(0)