mirror of
https://git.postgresql.org/git/postgresql.git
synced 2024-10-03 09:26:51 +02:00
This patch removes a use of uninitialized memory in lmgr/lock.c, by
adding a missing sprintf(). Neil Conway
This commit is contained in:
parent
3c104bc4ed
commit
5ad4faf13a
@ -8,7 +8,7 @@
|
|||||||
*
|
*
|
||||||
*
|
*
|
||||||
* IDENTIFICATION
|
* IDENTIFICATION
|
||||||
* $Header: /cvsroot/pgsql/src/backend/storage/lmgr/lock.c,v 1.115 2002/09/04 20:31:25 momjian Exp $
|
* $Header: /cvsroot/pgsql/src/backend/storage/lmgr/lock.c,v 1.116 2002/09/26 05:18:30 momjian Exp $
|
||||||
*
|
*
|
||||||
* NOTES
|
* NOTES
|
||||||
* Outside modules can create a lock table and acquire/release
|
* Outside modules can create a lock table and acquire/release
|
||||||
@ -256,6 +256,7 @@ LockMethodTableInit(char *tabName,
|
|||||||
shmemName = (char *) palloc(strlen(tabName) + 32);
|
shmemName = (char *) palloc(strlen(tabName) + 32);
|
||||||
|
|
||||||
/* each lock table has a non-shared, permanent header */
|
/* each lock table has a non-shared, permanent header */
|
||||||
|
sprintf(shmemName, "%s (lock method table)", tabName);
|
||||||
lockMethodTable = (LOCKMETHODTABLE *)
|
lockMethodTable = (LOCKMETHODTABLE *)
|
||||||
ShmemInitStruct(shmemName, sizeof(LOCKMETHODTABLE), &found);
|
ShmemInitStruct(shmemName, sizeof(LOCKMETHODTABLE), &found);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user