forked frompostgres/postgres
- Notifications
You must be signed in to change notification settings - Fork6
Commitf3baaf2

Etsuro Fujita
Fix rescanning of async-aware Append nodes.
In cases where run-time pruning isn't required, the synchronous andasynchronous subplans for an async-aware Append node determined usingclassify_matching_subplans() should be re-used when rescanning the node,but the previous code re-determined them using that function repeatedlyeach time when rescanning the node, leading to incorrect results in anormal build and an Assert failure in an Assert-enabled build as thatfunction doesn't assume that it's called repeatedly in such cases. Fixthe code as mentioned above.My oversight in commit27e1f14.While at it, initialize async-related pointers/variables to NULL/zeroexplicitly in ExecInitAppend() and ExecReScanAppend(), just to be sure.(The variables would have been set to zero before we get to the latterfunction, but let's do so.)Reviewed-by: Kyotaro HoriguchiDiscussion:https://postgr.es/m/CAPmGK16Q4B2_KY%2BJH7rb7wQbw54AUprp7TMekGTd2T1B62yysQ%40mail.gmail.com1 parenta65e9f3 commitf3baaf2
File tree
3 files changed
+76
-5
lines changed- contrib/postgres_fdw
- expected
- sql
- src/backend/executor
3 files changed
+76
-5
lines changedLines changed: 42 additions & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
9973 | 9973 |
| |
9974 | 9974 |
| |
9975 | 9975 |
| |
| 9976 | + | |
| 9977 | + | |
| 9978 | + | |
| 9979 | + | |
| 9980 | + | |
| 9981 | + | |
| 9982 | + | |
| 9983 | + | |
| 9984 | + | |
| 9985 | + | |
| 9986 | + | |
| 9987 | + | |
| 9988 | + | |
| 9989 | + | |
| 9990 | + | |
| 9991 | + | |
| 9992 | + | |
| 9993 | + | |
| 9994 | + | |
| 9995 | + | |
| 9996 | + | |
| 9997 | + | |
| 9998 | + | |
| 9999 | + | |
| 10000 | + | |
| 10001 | + | |
| 10002 | + | |
| 10003 | + | |
| 10004 | + | |
| 10005 | + | |
| 10006 | + | |
| 10007 | + | |
| 10008 | + | |
| 10009 | + | |
| 10010 | + | |
| 10011 | + | |
| 10012 | + | |
| 10013 | + | |
| 10014 | + | |
| 10015 | + | |
| 10016 | + | |
| 10017 | + | |
9976 | 10018 |
| |
9977 | 10019 |
| |
9978 | 10020 |
| |
|
Lines changed: 12 additions & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
3157 | 3157 |
| |
3158 | 3158 |
| |
3159 | 3159 |
| |
| 3160 | + | |
| 3161 | + | |
| 3162 | + | |
| 3163 | + | |
| 3164 | + | |
| 3165 | + | |
| 3166 | + | |
| 3167 | + | |
| 3168 | + | |
| 3169 | + | |
| 3170 | + | |
| 3171 | + | |
3160 | 3172 |
| |
3161 | 3173 |
| |
3162 | 3174 |
| |
|
Lines changed: 22 additions & 5 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
240 | 240 |
| |
241 | 241 |
| |
242 | 242 |
| |
243 |
| - | |
244 |
| - | |
| 243 | + | |
| 244 | + | |
| 245 | + | |
245 | 246 |
| |
246 | 247 |
| |
| 248 | + | |
247 | 249 |
| |
248 | 250 |
| |
249 | 251 |
| |
| |||
265 | 267 |
| |
266 | 268 |
| |
267 | 269 |
| |
| 270 | + | |
| 271 | + | |
| 272 | + | |
| 273 | + | |
| 274 | + | |
| 275 | + | |
268 | 276 |
| |
269 | 277 |
| |
270 | 278 |
| |
| |||
459 | 467 |
| |
460 | 468 |
| |
461 | 469 |
| |
| 470 | + | |
| 471 | + | |
462 | 472 |
| |
463 | 473 |
| |
464 | 474 |
| |
| |||
861 | 871 |
| |
862 | 872 |
| |
863 | 873 |
| |
| 874 | + | |
| 875 | + | |
| 876 | + | |
864 | 877 |
| |
865 | 878 |
| |
866 | 879 |
| |
867 | 880 |
| |
868 | 881 |
| |
| 882 | + | |
869 | 883 |
| |
870 | 884 |
| |
871 | 885 |
| |
872 |
| - | |
| 886 | + | |
| 887 | + | |
| 888 | + | |
| 889 | + | |
| 890 | + | |
| 891 | + | |
873 | 892 |
| |
874 | 893 |
| |
875 | 894 |
| |
| |||
1148 | 1167 |
| |
1149 | 1168 |
| |
1150 | 1169 |
| |
1151 |
| - | |
1152 | 1170 |
| |
1153 | 1171 |
| |
1154 | 1172 |
| |
1155 |
| - | |
1156 | 1173 |
|
0 commit comments
Comments
(0)