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

Commit3e99158

Browse files
Jan WieckJan Wieck
Jan Wieck
authored and
Jan Wieck
committed
update_pg_pwd() is an AR trigger. Corrected return type.
Jan
1 parentb57b0e0 commit3e99158

File tree

2 files changed

+13
-3
lines changed

2 files changed

+13
-3
lines changed

‎src/backend/commands/user.c

Lines changed: 12 additions & 2 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.46 1999/12/20 01:11:37 tgl Exp $
8+
* $Id: user.c,v 1.47 1999/12/21 22:39:01 wieck Exp $
99
*
1010
*-------------------------------------------------------------------------
1111
*/
@@ -24,6 +24,7 @@
2424
#include"catalog/indexing.h"
2525
#include"commands/copy.h"
2626
#include"commands/user.h"
27+
#include"commands/trigger.h"
2728
#include"libpq/crypt.h"
2829
#include"miscadmin.h"
2930
#include"nodes/pg_list.h"
@@ -48,13 +49,20 @@ static void CheckPgUserAclNotNull(void);
4849
*---------------------------------------------------------------------
4950
*/
5051

51-
void
52+
HeapTuple
5253
update_pg_pwd(void)
5354
{
5455
char*filename,
5556
*tempname;
5657
intbufsize;
5758

59+
60+
/*
61+
* This is a trigger, so clean out the information provided by
62+
* the trigger manager.
63+
*/
64+
CurrentTriggerData=NULL;
65+
5866
/*
5967
* Create a temporary filename to be renamed later. This prevents the
6068
* backend from clobbering the pg_pwd file while the postmaster might
@@ -93,6 +101,8 @@ update_pg_pwd(void)
93101
creat(filename,S_IRUSR |S_IWUSR);
94102

95103
pfree((void*)tempname);
104+
105+
returnNULL;
96106
}
97107

98108
/*---------------------------------------------------------------------

‎src/include/commands/user.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,6 +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);
24+
externHeapTupleupdate_pg_pwd(void);
2525

2626
#endif/* USER_H */

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp