Commit ac3aac3
committed
reorderbuffer: preserve errno while reporting error
Clobbering errno during cleanup after an error is an oft-repeated, easy
to make mistake. Deal with it here as everywhere else, by saving it
aside and restoring after cleanup, before ereport'ing.
In passing, add a missing errcode declaration in another ereport() call
in the same file, which I noticed while skimming the file looking for
similar problems.
Backpatch to 9.4, where this code was introduced.1 parent c4f1540 commit ac3aac3
1 file changed
+5
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2207 | 2207 | | |
2208 | 2208 | | |
2209 | 2209 | | |
| 2210 | + | |
| 2211 | + | |
2210 | 2212 | | |
| 2213 | + | |
2211 | 2214 | | |
2212 | 2215 | | |
2213 | 2216 | | |
| |||
2936 | 2939 | | |
2937 | 2940 | | |
2938 | 2941 | | |
2939 | | - | |
| 2942 | + | |
| 2943 | + | |
2940 | 2944 | | |
2941 | 2945 | | |
2942 | 2946 | | |
| |||
0 commit comments