Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commite74ce0a

Browse files
committed
As long as we're fixing this space calculation, let's actually do it
right. We should MAXALIGN the individual items because we'llallocate them individually, not as an array.
1 parentd106fd2 commite74ce0a

File tree

1 file changed

+3
-3
lines changed
  • src/backend/storage/lmgr

1 file changed

+3
-3
lines changed

‎src/backend/storage/lmgr/lock.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
*
99
*
1010
* IDENTIFICATION
11-
* $Header: /cvsroot/pgsql/src/backend/storage/lmgr/lock.c,v 1.84 2001/02/2318:28:46 momjian Exp $
11+
* $Header: /cvsroot/pgsql/src/backend/storage/lmgr/lock.c,v 1.85 2001/02/2320:12:37 tgl Exp $
1212
*
1313
* NOTES
1414
* Outside modules can create a lock table and acquire/release
@@ -1410,8 +1410,8 @@ LockShmemSize(int maxBackends)
14101410
intsize=0;
14111411

14121412
size+=MAXALIGN(sizeof(PROC_HDR));/* ProcGlobal */
1413-
size+=MAXALIGN(maxBackends*sizeof(PROC));/* each MyProc */
1414-
size+=MAXALIGN(MAX_LOCK_METHODS*sizeof(LOCKMETHODCTL));/* each lockMethodTable->ctl */
1413+
size+=maxBackends*MAXALIGN(sizeof(PROC));/* each MyProc */
1414+
size+=MAX_LOCK_METHODS*MAXALIGN(sizeof(LOCKMETHODCTL));/* each lockMethodTable->ctl */
14151415

14161416
/* lockHash table */
14171417
size+=hash_estimate_size(NLOCKENTS(maxBackends),

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp