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

Commit40a89e0

Browse files
committed
Cleanups.
1 parentfb38a5d commit40a89e0

File tree

7 files changed

+36
-18
lines changed

7 files changed

+36
-18
lines changed

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

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
*
88
*
99
* IDENTIFICATION
10-
* $Header: /cvsroot/pgsql/src/backend/storage/lmgr/lmgr.c,v 1.28 1999/07/1515:19:51 momjian Exp $
10+
* $Header: /cvsroot/pgsql/src/backend/storage/lmgr/lmgr.c,v 1.29 1999/07/1520:32:27 momjian Exp $
1111
*
1212
*-------------------------------------------------------------------------
1313
*/
@@ -47,7 +47,7 @@
4747

4848
externOidMyDatabaseId;
4949

50-
staticMASKLockConflicts[]= {
50+
staticLOCKMASKLockConflicts[]= {
5151
(int)NULL,
5252

5353
/* AccessShareLock */

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

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
*
88
*
99
* IDENTIFICATION
10-
* $Header: /cvsroot/pgsql/src/backend/storage/lmgr/lock.c,v 1.56 1999/07/1515:19:52 momjian Exp $
10+
* $Header: /cvsroot/pgsql/src/backend/storage/lmgr/lock.c,v 1.57 1999/07/1520:32:27 momjian Exp $
1111
*
1212
* NOTES
1313
* Outside modules can create a lock table and acquire/release
@@ -162,8 +162,8 @@ SPINLOCKLockMgrLock;/* in Shmem or created in
162162

163163
/* This is to simplify/speed up some bit arithmetic */
164164

165-
staticMASKBITS_OFF[MAX_LOCKMODES];
166-
staticMASKBITS_ON[MAX_LOCKMODES];
165+
staticLOCKMASKBITS_OFF[MAX_LOCKMODES];
166+
staticLOCKMASKBITS_ON[MAX_LOCKMODES];
167167

168168
/* -----------------
169169
* XXX Want to move this to this file
@@ -231,7 +231,7 @@ LockDisable(int status)
231231
*/
232232
staticvoid
233233
LockMethodInit(LOCKMETHODTABLE*lockMethodTable,
234-
MASK*conflictsP,
234+
LOCKMASK*conflictsP,
235235
int*prioP,
236236
intnumModes)
237237
{
@@ -258,7 +258,7 @@ LockMethodInit(LOCKMETHODTABLE *lockMethodTable,
258258
*/
259259
LOCKMETHOD
260260
LockMethodTableInit(char*tabName,
261-
MASK*conflictsP,
261+
LOCKMASK*conflictsP,
262262
int*prioP,
263263
intnumModes)
264264
{

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

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
*
1313
*
1414
* IDENTIFICATION
15-
* $Header: /cvsroot/pgsql/src/backend/storage/lmgr/Attic/multi.c,v 1.29 1999/05/25 16:11:22 momjian Exp $
15+
* $Header: /cvsroot/pgsql/src/backend/storage/lmgr/Attic/multi.c,v 1.30 1999/07/15 20:32:27 momjian Exp $
1616
*
1717
* NOTES:
1818
* (1) The lock.c module assumes that the caller here is doing
@@ -41,7 +41,7 @@ static bool MultiRelease(LOCKMETHOD lockmethod, LOCKTAG *tag,
4141
* WRITE conflict between the tuple's intent lock and the relation's
4242
* write lock.
4343
*/
44-
staticMASKMultiConflicts[]= {
44+
staticLOCKMASKMultiConflicts[]= {
4545
(int)NULL,
4646
/* All reads and writes at any level conflict with a write lock */
4747
(1 <<WRITE_LOCK) | (1 <<WRITE_INTENT) | (1 <<READ_LOCK) | (1 <<READ_INTENT),

‎src/include/optimizer/geqo_random.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
*
66
* Copyright (c) 1994, Regents of the University of California
77
*
8-
* $Id: geqo_random.h,v 1.4 1999/02/13 23:21:48 momjian Exp $
8+
* $Id: geqo_random.h,v 1.5 1999/07/15 20:32:28 momjian Exp $
99
*
1010
*-------------------------------------------------------------------------
1111
*/
@@ -25,9 +25,9 @@
2525

2626
#include<math.h>
2727

28-
#defineMASK 2147483647
28+
#defineGEQOMASK 2147483647
2929

30-
#definegeqo_rand() ((double)random()/MASK)
30+
#definegeqo_rand() ((double)random()/GEQOMASK)
3131

3232
/* geqo_randint returns integer value
3333
between lower and upper inclusive */

‎src/include/storage/lock.h

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
*
77
* Copyright (c) 1994, Regents of the University of California
88
*
9-
* $Id: lock.h,v 1.30 1999/06/01 09:35:39 vadim Exp $
9+
* $Id: lock.h,v 1.31 1999/07/15 20:32:29 momjian Exp $
1010
*
1111
*-------------------------------------------------------------------------
1212
*/
@@ -19,7 +19,7 @@
1919
#include<utils/array.h>
2020

2121
externSPINLOCKLockMgrLock;
22-
typedefintMASK;
22+
typedefintLOCKMASK;
2323

2424
#defineINIT_TABLE_SIZE100
2525
#defineMAX_TABLE_SIZE1000
@@ -41,7 +41,7 @@ typedef int MASK;
4141
typedefintLOCKMODE;
4242
typedefintLOCKMETHOD;
4343

44-
/* MAX_LOCKMODES cannot be larger than the bits inMASK */
44+
/* MAX_LOCKMODES cannot be larger than the bits inLOCKMASK */
4545
#defineMAX_LOCKMODES8
4646

4747
/*
@@ -241,7 +241,7 @@ extern SPINLOCK LockMgrLock;
241241
*/
242242
externvoidInitLocks(void);
243243
externvoidLockDisable(intstatus);
244-
externLOCKMETHODLockMethodTableInit(char*tabName,MASK*conflictsP,
244+
externLOCKMETHODLockMethodTableInit(char*tabName,LOCKMASK*conflictsP,
245245
int*prioP,intnumModes);
246246
externLOCKMETHODLockMethodTableRename(LOCKMETHODlockmethod);
247247
externboolLockAcquire(LOCKMETHODlockmethod,LOCKTAG*locktag,

‎src/tools/pginclude/pgfixinclude

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
:
2+
trap "rm -f /tmp/$$.c /tmp/$$.o /tmp/$$ /tmp/$$a /tmp/$$b" 0 1 2 3 15
3+
find . \( -name CVS -a -prune \) -o -type f -print |
4+
while read FILE
5+
do
6+
cat /tmp/$$a | grep "^#include" |
7+
sed 's/^#include[ ]*[<"]\([^>"]*\).*$/\1/g' |
8+
while read INCLUDE
9+
do
10+
if [ -s /usr/include/"$INCLUDE" ]
11+
thencat "$FILE" |
12+
sed 's/^#include[ ]*[<"]'"$INCLUDE"'[>"]$/#include <'"$INCLUDE"'>/g' >/tmp/$$
13+
elsecat "$FILE" |
14+
sed 's/^#include[ ]*[<"]'"$INCLUDE"'[>"]$/#include "'"$INCLUDE"'"/g' >/tmp/$$
15+
fi
16+
cat /tmp/$$ > "$FILE"
17+
done
18+
done

‎src/tools/pginclude/pgnoinclude

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ do
1414
elsecat "$FILE" >/tmp/$$a
1515
fi
1616
cat /tmp/$$a | grep "^#include" |
17-
sed 's/#include[ ]*[<"]\([^>"]*\).*$/\1/g' |
17+
sed 's/^#include[ ]*[<"]\([^>"]*\).*$/\1/g' |
1818
while read INCLUDE
1919
do
2020
[ -s /usr/include/$INCLUDE ] && continue
@@ -36,7 +36,7 @@ do
3636
if [ "$?" -eq 0 ]
3737
thenecho "$FILE $INCLUDE"
3838
if [ "$IS_INCLUDE" = "N" ]
39-
thengrep -v '#include[ ]*[<"]$INCLUDE[>"]' $FILE >/tmp/$$b
39+
thengrep -v '^#include[ ][ ]*[<"]'"$INCLUDE"'[>"]' $FILE >/tmp/$$b
4040
mv /tmp/$$b "$FILE"
4141
fi
4242
if [ "$1" = "-v" ]

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp