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

Commit856da1e

Browse files
committed
Constlen can be -1, so make it a signed type.
1 parent7b30490 commit856da1e

File tree

5 files changed

+13
-13
lines changed

5 files changed

+13
-13
lines changed

‎src/backend/nodes/makefuncs.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/nodes/makefuncs.c,v 1.7 1998/02/10 16:03:17 momjian Exp $
10+
* $Header: /cvsroot/pgsql/src/backend/nodes/makefuncs.c,v 1.8 1998/02/21 16:58:22 momjian Exp $
1111
*
1212
* NOTES
1313
* Creator functions in POSTGRES 4.2 are generated automatically. Most of
@@ -102,7 +102,7 @@ makeResdom(AttrNumber resno,
102102
*/
103103
Const*
104104
makeConst(Oidconsttype,
105-
Sizeconstlen,
105+
intconstlen,
106106
Datumconstvalue,
107107
boolconstisnull,
108108
boolconstbyval,

‎src/backend/nodes/outfuncs.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/nodes/outfuncs.c,v 1.30 1998/02/13 03:27:45 vadim Exp $
10+
* $Header: /cvsroot/pgsql/src/backend/nodes/outfuncs.c,v 1.31 1998/02/21 16:58:24 momjian Exp $
1111
*
1212
* NOTES
1313
* Every (plan) node in POSTGRES has an associated "out" routine which
@@ -629,7 +629,7 @@ _outResdom(StringInfo str, Resdom *node)
629629
charbuf[500];
630630

631631
appendStringInfo(str,"RESDOM");
632-
sprintf(buf," :resno %hd ",node->resno);
632+
sprintf(buf," :resno %d ",node->resno);
633633
appendStringInfo(str,buf);
634634
sprintf(buf," :restype %u ",node->restype);
635635
appendStringInfo(str,buf);
@@ -724,7 +724,7 @@ _outVar(StringInfo str, Var *node)
724724
appendStringInfo(str,"VAR");
725725
sprintf(buf," :varno %d ",node->varno);
726726
appendStringInfo(str,buf);
727-
sprintf(buf," :varattno %hd ",node->varattno);
727+
sprintf(buf," :varattno %d ",node->varattno);
728728
appendStringInfo(str,buf);
729729
sprintf(buf," :vartype %u ",node->vartype);
730730
appendStringInfo(str,buf);
@@ -749,7 +749,7 @@ _outConst(StringInfo str, Const *node)
749749
appendStringInfo(str,"CONST");
750750
sprintf(buf," :consttype %u ",node->consttype);
751751
appendStringInfo(str,buf);
752-
sprintf(buf," :constlen %hd ",node->constlen);
752+
sprintf(buf," :constlen %d ",node->constlen);
753753
appendStringInfo(str,buf);
754754
appendStringInfo(str," :constisnull ");
755755
appendStringInfo(str,node->constisnull ?"true" :"false");
@@ -931,7 +931,7 @@ _outParam(StringInfo str, Param *node)
931931
appendStringInfo(str,"PARAM");
932932
sprintf(buf," :paramkind %d ",node->paramkind);
933933
appendStringInfo(str,buf);
934-
sprintf(buf," :paramid %hd ",node->paramid);
934+
sprintf(buf," :paramid %d ",node->paramid);
935935
appendStringInfo(str,buf);
936936
appendStringInfo(str," :paramname ");
937937
appendStringInfo(str,node->paramname);

‎src/backend/nodes/readfuncs.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/nodes/readfuncs.c,v 1.25 1998/02/13 03:27:47 vadim Exp $
10+
* $Header: /cvsroot/pgsql/src/backend/nodes/readfuncs.c,v 1.26 1998/02/21 16:58:26 momjian Exp $
1111
*
1212
* NOTES
1313
* Most of the read functions for plan nodes are tested. (In fact, they
@@ -947,7 +947,7 @@ _readConst()
947947

948948
token=lsptok(NULL,&length);/* get :constlen */
949949
token=lsptok(NULL,&length);/* now read it */
950-
local_node->constlen=strtoul(token,NULL,10);
950+
local_node->constlen=strtol(token,NULL,10);
951951

952952
token=lsptok(NULL,&length);/* get :constisnull */
953953
token=lsptok(NULL,&length);/* now read it */

‎src/include/nodes/makefuncs.h‎

Lines changed: 2 additions & 2 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: makefuncs.h,v 1.9 1998/02/10 16:04:24 momjian Exp $
9+
* $Id: makefuncs.h,v 1.10 1998/02/21 16:58:45 momjian Exp $
1010
*
1111
*-------------------------------------------------------------------------
1212
*/
@@ -39,7 +39,7 @@ extern Resdom * makeResdom(AttrNumber resno,
3939
intresjunk);
4040

4141
externConst*makeConst(Oidconsttype,
42-
Sizeconstlen,
42+
intconstlen,
4343
Datumconstvalue,
4444
boolconstisnull,
4545
boolconstbyval,

‎src/include/nodes/primnodes.h‎

Lines changed: 2 additions & 2 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: primnodes.h,v 1.19 1998/02/13 03:45:29 vadim Exp $
9+
* $Id: primnodes.h,v 1.20 1998/02/21 16:58:49 momjian Exp $
1010
*
1111
*-------------------------------------------------------------------------
1212
*/
@@ -181,7 +181,7 @@ typedef struct Const
181181
{
182182
NodeTagtype;
183183
Oidconsttype;
184-
Sizeconstlen;
184+
intconstlen;
185185
Datumconstvalue;
186186
boolconstisnull;
187187
boolconstbyval;

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp