Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

Commit a05ed5b

Browse files
committed
Fixes:
In postgres95/src/backend/nodes/readfuncs, lines 1188 and 1189, local_node->relname is taken to point to a NameType, while its defined as a pointer to char. Both the casting to Name and the call of namestrcpy should, IMHO, be changed appropriately (first patch). As far as I could see from the Linux signal header file, a signal handler is declared as typedef void (*__sighandler_t)(int); Few changes to postgres95/src/backend/storage/lmgr/proc.c seem appropriate to comply with this. Finally, postgres95/src/bin/pg_version/pg_version.c defines a function GetDataHome (by default, returning an integer) and returns NULL in the function, which isn't an integer... Submitted by: ernst.molitor@uni-bonn.de
1 parent 4477b6f commit a05ed5b

File tree

3 files changed

+10
-9
lines changed

3 files changed

+10
-9
lines changed

src/backend/nodes/readfuncs.c

+3-3
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
*
88
*
99
* IDENTIFICATION
10-
* $Header: /cvsroot/pgsql/src/backend/nodes/readfuncs.c,v 1.1.1.1 1996/07/09 06:21:33 scrappy Exp $
10+
* $Header: /cvsroot/pgsql/src/backend/nodes/readfuncs.c,v 1.2 1996/07/31 02:18:48 scrappy Exp $
1111
*
1212
* NOTES
1313
* Most of the read functions for plan nodes are tested. (In fact, they
@@ -1185,8 +1185,8 @@ _readRangeTblEntry()
11851185
token++;
11861186
token[length - 2] = '\0';
11871187

1188-
local_node->relname = (Name) palloc(NAMEDATALEN);
1189-
namestrcpy(local_node->relname, token);
1188+
local_node->relname = (char *) palloc(NAMEDATALEN);
1189+
strcpy(local_node->relname, token);
11901190
token[length - 2] = '\"';
11911191
}
11921192

src/backend/storage/lmgr/proc.c

+5-4
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
*
88
*
99
* IDENTIFICATION
10-
* $Header: /cvsroot/pgsql/src/backend/storage/lmgr/proc.c,v 1.3 1996/07/25 19:45:31 scrappy Exp $
10+
* $Header: /cvsroot/pgsql/src/backend/storage/lmgr/proc.c,v 1.4 1996/07/31 02:19:09 scrappy Exp $
1111
*
1212
*-------------------------------------------------------------------------
1313
*/
@@ -46,7 +46,7 @@
4646
* This is so that we can support more backends. (system-wide semaphore
4747
* sets run out pretty fast.) -ay 4/95
4848
*
49-
* $Header: /cvsroot/pgsql/src/backend/storage/lmgr/proc.c,v 1.3 1996/07/25 19:45:31 scrappy Exp $
49+
* $Header: /cvsroot/pgsql/src/backend/storage/lmgr/proc.c,v 1.4 1996/07/31 02:19:09 scrappy Exp $
5050
*/
5151
#include <sys/time.h>
5252
#ifndef WIN32
@@ -96,7 +96,7 @@ static void ProcKill(int exitStatus, int pid);
9696
static void ProcGetNewSemKeyAndNum(IPCKey *key, int *semNum);
9797
static void ProcFreeSem(IpcSemaphoreKey semKey, int semNum);
9898
#if defined(PORTNAME_linux)
99-
extern int HandleDeadLock(int);
99+
extern void HandleDeadLock(int);
100100
#else
101101
extern int HandleDeadLock(void);
102102
#endif
@@ -628,10 +628,11 @@ ProcAddLock(SHM_QUEUE *elem)
628628
* up my semaphore.
629629
* --------------------
630630
*/
631-
int
632631
#if defined(PORTNAME_linux)
632+
void
633633
HandleDeadLock(int i)
634634
#else
635+
int
635636
HandleDeadLock()
636637
#endif
637638
{

src/bin/pg_version/pg_version.c

+2-2
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
*
88
*
99
* IDENTIFICATION
10-
* $Header: /cvsroot/pgsql/src/bin/pg_version/Attic/pg_version.c,v 1.1.1.1 1996/07/09 06:22:14 scrappy Exp $
10+
* $Header: /cvsroot/pgsql/src/bin/pg_version/Attic/pg_version.c,v 1.2 1996/07/31 02:19:23 scrappy Exp $
1111
*
1212
*-------------------------------------------------------------------------
1313
*/
@@ -31,5 +31,5 @@ elog() {}
3131

3232
GetDataHome()
3333
{
34-
return(NULL);
34+
return(0);
3535
}

0 commit comments

Comments
 (0)