Commit 25dc142
committed
Avoid GatherMerge crash when there are no workers.
It's unnecessary to return an actual slot when we have no tuple.
We can just return NULL, which avoids the risk of indexing into an
array that might not contain any elements.
Rushabh Lathia, per a report from Tomas Vondra
Discussion: http://postgr.es/m/6ecd6f17-0dcf-1de7-ded8-0de7db1ddc88@2ndquadrant.com1 parent 7d8f698 commit 25dc142
1 file changed
+4
-7
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
419 | 419 | | |
420 | 420 | | |
421 | 421 | | |
422 | | - | |
423 | | - | |
| 422 | + | |
424 | 423 | | |
425 | | - | |
| 424 | + | |
426 | 425 | | |
427 | 426 | | |
428 | 427 | | |
| |||
437 | 436 | | |
438 | 437 | | |
439 | 438 | | |
440 | | - | |
441 | | - | |
442 | | - | |
443 | 439 | | |
444 | 440 | | |
445 | 441 | | |
| |||
479 | 475 | | |
480 | 476 | | |
481 | 477 | | |
482 | | - | |
| 478 | + | |
| 479 | + | |
483 | 480 | | |
484 | 481 | | |
485 | 482 | | |
| |||
0 commit comments