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

Commit0df7f49

Browse files
committed
Clean up possibly-uninitialized-variable warnings reported by gcc 4.x.
1 parent030d5bd commit0df7f49

File tree

3 files changed

+10
-8
lines changed

3 files changed

+10
-8
lines changed

‎contrib/intarray/_int_bool.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,8 @@ gettoken(WORKSTATE * state, int4 *val)
5858
charnnn[16],
5959
*curnnn;
6060

61+
*val=0;/* default result */
62+
6163
curnnn=nnn;
6264
while (1)
6365
{

‎contrib/ltree/ltxtquery_io.c

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -197,13 +197,13 @@ pushval_asis(QPRS_STATE * state, int type, char *strval, int lenval, uint16 flag
197197
staticint4
198198
makepol(QPRS_STATE*state)
199199
{
200-
int4val,
200+
int4val=0,
201201
type;
202-
int4lenval;
203-
char*strval;
202+
int4lenval=0;
203+
char*strval=NULL;
204204
int4stack[STACKDEPTH];
205205
int4lenstack=0;
206-
uint16flag;
206+
uint16flag=0;
207207

208208
while ((type=gettoken_query(state,&val,&lenval,&strval,&flag))!=END)
209209
{

‎contrib/tsearch2/query.c

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -317,13 +317,13 @@ pushval_morph(QPRS_STATE * state, int typeval, char *strval, int lenval, int2 we
317317
staticint4
318318
makepol(QPRS_STATE*state,void (*pushval) (QPRS_STATE*,int,char*,int,int2))
319319
{
320-
int4val,
320+
int4val=0,
321321
type;
322-
int4lenval;
323-
char*strval;
322+
int4lenval=0;
323+
char*strval=NULL;
324324
int4stack[STACKDEPTH];
325325
int4lenstack=0;
326-
int2weight;
326+
int2weight=0;
327327

328328
while ((type=gettoken_query(state,&val,&lenval,&strval,&weight))!=END)
329329
{

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp