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

Commit9392299

Browse files
committed
Clean up some minor gcc warnings.
1 parentc16afb4 commit9392299

File tree

6 files changed

+15
-20
lines changed

6 files changed

+15
-20
lines changed

‎src/backend/commands/dbcommands.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,12 +7,13 @@
77
*
88
*
99
* IDENTIFICATION
10-
* $Header: /cvsroot/pgsql/src/backend/commands/dbcommands.c,v 1.47 1999/12/12 05:15:10 momjian Exp $
10+
* $Header: /cvsroot/pgsql/src/backend/commands/dbcommands.c,v 1.48 1999/12/20 01:11:37 tgl Exp $
1111
*
1212
*-------------------------------------------------------------------------
1313
*/
1414
#include<signal.h>
1515
#include<sys/stat.h>
16+
#include<unistd.h>
1617

1718
#include"postgres.h"
1819

‎src/backend/commands/user.c

Lines changed: 6 additions & 11 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: user.c,v 1.45 1999/12/16 17:24:13 momjian Exp $
8+
* $Id: user.c,v 1.46 1999/12/20 01:11:37 tgl Exp $
99
*
1010
*-------------------------------------------------------------------------
1111
*/
@@ -37,7 +37,7 @@ static void CheckPgUserAclNotNull(void);
3737
#defineSQL_LENGTH512
3838

3939
/*---------------------------------------------------------------------
40-
*UpdatePgPwdFile
40+
*update_pg_pwd
4141
*
4242
* copy the modified contents of pg_shadow to a file used by the postmaster
4343
* for user authentication. The file is stored as $PGDATA/pg_pwd.
@@ -48,12 +48,8 @@ static void CheckPgUserAclNotNull(void);
4848
*---------------------------------------------------------------------
4949
*/
5050

51-
/* This is the old name. Now uses a lower case name to be able to call this
52-
from SQL. */
53-
#defineUpdatePgPwdFile() update_pg_pwd()
54-
5551
void
56-
update_pg_pwd()
52+
update_pg_pwd(void)
5753
{
5854
char*filename,
5955
*tempname;
@@ -242,7 +238,7 @@ DefineUser(CreateUserStmt *stmt, CommandDest dest)
242238
* we can be sure no other backend will try to write the flat
243239
* file at the same time.
244240
*/
245-
UpdatePgPwdFile();
241+
update_pg_pwd();
246242

247243
/*
248244
* Now we can clean up.
@@ -391,7 +387,7 @@ AlterUser(AlterUserStmt *stmt, CommandDest dest)
391387
* we can be sure no other backend will try to write the flat
392388
* file at the same time.
393389
*/
394-
UpdatePgPwdFile();
390+
update_pg_pwd();
395391

396392
/*
397393
* Now we can clean up.
@@ -524,7 +520,7 @@ RemoveUser(char *user, CommandDest dest)
524520
* we can be sure no other backend will try to write the flat
525521
* file at the same time.
526522
*/
527-
UpdatePgPwdFile();
523+
update_pg_pwd();
528524

529525
/*
530526
* Now we can clean up.
@@ -758,7 +754,6 @@ AlterGroup(AlterGroupStmt *stmt, CommandDest dest)
758754
*/
759755
if (stmt->action==0)/* change sysid */
760756
{
761-
boolsysid_exists= false;
762757
ScanKeyDatakeys[2];
763758
HeapTupletuple;
764759
HeapScanDescscan;

‎src/backend/executor/nodeTidscan.c

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
*
88
*
99
* IDENTIFICATION
10-
* $Header: /cvsroot/pgsql/src/backend/executor/nodeTidscan.c,v 1.2 1999/12/16 22:19:44 wieck Exp $
10+
* $Header: /cvsroot/pgsql/src/backend/executor/nodeTidscan.c,v 1.3 1999/12/20 01:14:33 tgl Exp $
1111
*
1212
*-------------------------------------------------------------------------
1313
*/
@@ -104,8 +104,6 @@ TidNext(TidScan *node)
104104
if (estate->es_evTuple!=NULL&&
105105
estate->es_evTuple[node->scan.scanrelid-1]!=NULL)
106106
{
107-
intiptr,numQuals;
108-
109107
ExecClearTuple(slot);
110108
if (estate->es_evTupleNull[node->scan.scanrelid-1])
111109
returnslot;/* return empty slot */

‎src/backend/tcop/pquery.c

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
*
88
*
99
* IDENTIFICATION
10-
* $Header: /cvsroot/pgsql/src/backend/tcop/pquery.c,v 1.28 1999/09/24 00:24:53 tgl Exp $
10+
* $Header: /cvsroot/pgsql/src/backend/tcop/pquery.c,v 1.29 1999/12/20 01:19:11 tgl Exp $
1111
*
1212
*-------------------------------------------------------------------------
1313
*/
@@ -54,7 +54,6 @@ EState *
5454
CreateExecutorState(void)
5555
{
5656
EState*state;
57-
externintNBuffers;
5857

5958
/* ----------------
6059
*create a new executor state

‎src/backend/utils/adt/tid.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
*
88
*
99
* IDENTIFICATION
10-
* $Header: /cvsroot/pgsql/src/backend/utils/adt/tid.c,v 1.12 1999/10/11 06:28:26 inoue Exp $
10+
* $Header: /cvsroot/pgsql/src/backend/utils/adt/tid.c,v 1.13 1999/12/20 01:23:04 tgl Exp $
1111
*
1212
* NOTES
1313
* input routine largely stolen from boxin().
@@ -144,7 +144,7 @@ text_tid(const text *string)
144144

145145
if (!string)return (ItemPointer)0;
146146

147-
str=textout(string);
147+
str=textout((text*)string);
148148
result=tidin(str);
149149
pfree(str);
150150

@@ -188,7 +188,7 @@ currtid_byrelname(const text *relname, ItemPointer tid)
188188

189189
if (!relname)returnresult;
190190

191-
str=textout(relname);
191+
str=textout((text*)relname);
192192

193193
result= (ItemPointer)palloc(sizeof(ItemPointerData));
194194
ItemPointerSetInvalid(result);

‎src/include/commands/user.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,4 +21,6 @@ extern void CreateGroup(CreateGroupStmt *stmt, CommandDest dest);
2121
externvoidAlterGroup(AlterGroupStmt*stmt,CommandDestdest);
2222
externvoidDropGroup(DropGroupStmt*stmt,CommandDestdest);
2323

24+
externvoidupdate_pg_pwd(void);
25+
2426
#endif/* USER_H */

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp