forked frompostgres/postgres
- Notifications
You must be signed in to change notification settings - Fork6
Commitdab889d
committed
Fix min_dynamic_shared_memory on Windows.
When min_dynamic_shared_memory is set above 0, we try to find space in apre-allocated region of the main shared memory area instead of callingdsm_impl_XXX() routines to allocate more. The dsm_pin_segment() anddsm_unpin_segment() routines had a bug: they called dsm_impl_XXX()routines even for main region segments. Nobody noticed before nowbecause those routines do nothing on Unix, but on Windows they'd failwhile attempting to duplicate an invalid Windows HANDLE. Add themissing gating.Back-patch to 14, where commit84b1c63 added this feature. Fixespgsql-bugs bug #18165.Reported-by: Maxime Boyer <maxime.boyer@cra-arc.gc.ca>Tested-by: Alexander Lakhin <exclusion@gmail.com>Discussion:https://postgr.es/m/18165-bf4f525cea6e51de%40postgresql.org1 parent2d870b4 commitdab889d
1 file changed
+6
-4
lines changedLines changed: 6 additions & 4 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
927 | 927 |
| |
928 | 928 |
| |
929 | 929 |
| |
930 |
| - | |
| 930 | + | |
931 | 931 |
| |
932 | 932 |
| |
933 | 933 |
| |
| |||
938 | 938 |
| |
939 | 939 |
| |
940 | 940 |
| |
941 |
| - | |
| 941 | + | |
| 942 | + | |
942 | 943 |
| |
943 | 944 |
| |
944 | 945 |
| |
| |||
995 | 996 |
| |
996 | 997 |
| |
997 | 998 |
| |
998 |
| - | |
999 |
| - | |
| 999 | + | |
| 1000 | + | |
| 1001 | + | |
1000 | 1002 |
| |
1001 | 1003 |
| |
1002 | 1004 |
| |
|
0 commit comments
Comments
(0)