forked frompostgres/postgres
- Notifications
You must be signed in to change notification settings - Fork6
Commitc018786
committed
Fix crash when using COLLATE in partition bound expressions
Attempting to use a COLLATE clause with a type that it not collatable ina partition bound expression could crash the server. This commit fixesthe code by adding more checks similar to what is done when computingindex or partition attributes by making sure that there is a collationiff the type is collatable.Backpatch down to 12, as7c079d7 introduced this problem.Reported-by: Alexander LakhinAuthor: Dmitry DolgovDiscussion:https://postgr.es/m/16325-809194cf742313ab@postgresql.orgBackpatch-through: 121 parentd025cf8 commitc018786
File tree
3 files changed
+32
-0
lines changed- src
- backend/parser
- test/regress
- expected
- sql
3 files changed
+32
-0
lines changedLines changed: 24 additions & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
4081 | 4081 |
| |
4082 | 4082 |
| |
4083 | 4083 |
| |
| 4084 | + | |
| 4085 | + | |
| 4086 | + | |
| 4087 | + | |
| 4088 | + | |
| 4089 | + | |
| 4090 | + | |
| 4091 | + | |
| 4092 | + | |
| 4093 | + | |
| 4094 | + | |
| 4095 | + | |
| 4096 | + | |
| 4097 | + | |
| 4098 | + | |
| 4099 | + | |
| 4100 | + | |
| 4101 | + | |
| 4102 | + | |
| 4103 | + | |
| 4104 | + | |
| 4105 | + | |
| 4106 | + | |
| 4107 | + | |
4084 | 4108 |
| |
4085 | 4109 |
| |
4086 | 4110 |
| |
|
Lines changed: 6 additions & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
652 | 652 |
| |
653 | 653 |
| |
654 | 654 |
| |
| 655 | + | |
| 656 | + | |
| 657 | + | |
| 658 | + | |
| 659 | + | |
| 660 | + | |
655 | 661 |
| |
656 | 662 |
| |
657 | 663 |
| |
|
Lines changed: 2 additions & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
549 | 549 |
| |
550 | 550 |
| |
551 | 551 |
| |
| 552 | + | |
| 553 | + | |
552 | 554 |
| |
553 | 555 |
| |
554 | 556 |
| |
|
0 commit comments
Comments
(0)