Skip to content

Commit

Permalink
fix some warnings of uninitialized variables (postgres-plr#158)
Browse files Browse the repository at this point in the history
  • Loading branch information
davecramer authored Aug 2, 2024
1 parent 6404833 commit 472cc93
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
6 changes: 3 additions & 3 deletions pg_conversion.c
Original file line number Diff line number Diff line change
Expand Up @@ -337,7 +337,7 @@ SEXP
pg_window_frame_get_r(WindowObject winobj, int argno, plr_function* function)
{
char buf[256];
SEXP result, v, names, row_names;
SEXP result, v, names = R_NilValue, row_names;
int64 i, num_frame_row = 0;
int j, nc = 1, nc_effective = 1, df_colnum = 0;
Datum dvalue;
Expand All @@ -346,11 +346,11 @@ pg_window_frame_get_r(WindowObject winobj, int argno, plr_function* function)
Oid element_type = function->arg_typid[argno];
FmgrInfo out_func = function->arg_out_func[argno];
/* for tuple arguments */
HeapTuple tuple;
HeapTuple tuple = NULL;
HeapTupleHeader tuple_hdr;
Oid tupType;
int32 tupTypmod;
TupleDesc tupdesc;
TupleDesc tupdesc = NULL;
/* for array arguments */
Oid typelem = function->arg_elem[argno];
int16 typlen;
Expand Down
2 changes: 1 addition & 1 deletion plr.c
Original file line number Diff line number Diff line change
Expand Up @@ -1625,7 +1625,7 @@ plr_convertargs(plr_function *function, Datum *arg, bool *argnull, FunctionCallI
int c = 0;
SEXP rargs,
t,
el;
el = R_NilValue;

#ifdef HAVE_WINDOW_FUNCTIONS
if (function->iswindow)
Expand Down

0 comments on commit 472cc93

Please sign in to comment.