We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see ourdocumentation.
There was an error while loading.Please reload this page.
1 parentfd6cee0 commit9afcafbCopy full SHA for 9afcafb
engine.c
@@ -515,14 +515,14 @@ assign_ptrack_map_size(int newval, void *extra)
515
if (newval!=0&& !XLogIsNeeded())
516
ereport(ERROR,
517
(errmsg("assign_ptrack_map_size: cannot use ptrack if wal_level is minimal"),
518
-errdetail("Set wal_level to \"replica\" or higher, or turn off ptrack with \"ptrack_map_size=0\"")));
+errdetail("Set wal_level to \"replica\" or higher, or turn off ptrack with \"ptrack.map_size=0\"")));
519
520
if (DataDir!=NULL&&
521
!IsBootstrapProcessingMode()&&
522
!InitializingParallelWorker)
523
{
524
-/*Always assign ptrack_map_size */
525
-ptrack_map_size=newval*1024*1024;
+/*Cast to uint64 in order to avoid int32 overflow */
+ptrack_map_size=(uint64)1024*1024*newval;
526
527
elog(DEBUG1,"assign_ptrack_map_size: ptrack_map_size set to "UINT64_FORMAT,
528
ptrack_map_size);