Skip to content

Commit 74b4d78

Browse files
author
Amit Kapila
committed
Removal unused function parameter in CopyReadBinaryAttribute.
The function parameter column_no is not used in CopyReadBinaryAttribute, this can be removed. Commit 0e319c7 removed the usage of column_no parameter in function CopyReadBinaryAttribute but forgot to remove the parameter. Reported-by: Vignesh C Author: Vignesh C Discussion: https://postgr.es/m/CALDaNm1TYSNTfqx_jfz9_mwEZ2Er=dZnu++duXpC1uQo1cG=WA@mail.gmail.com
1 parent ae3259c commit 74b4d78

File tree

1 file changed

+2
-7
lines changed

1 file changed

+2
-7
lines changed

src/backend/commands/copy.c

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -367,8 +367,7 @@ static bool CopyReadLine(CopyState cstate);
367367
static bool CopyReadLineText(CopyState cstate);
368368
static int CopyReadAttributesText(CopyState cstate);
369369
static int CopyReadAttributesCSV(CopyState cstate);
370-
static Datum CopyReadBinaryAttribute(CopyState cstate,
371-
int column_no, FmgrInfo *flinfo,
370+
static Datum CopyReadBinaryAttribute(CopyState cstate, FmgrInfo *flinfo,
372371
Oid typioparam, int32 typmod,
373372
bool *isnull);
374373
static void CopyAttributeOutText(CopyState cstate, char *string);
@@ -3776,17 +3775,14 @@ NextCopyFrom(CopyState cstate, ExprContext *econtext,
37763775
errmsg("row field count is %d, expected %d",
37773776
(int) fld_count, attr_count)));
37783777

3779-
i = 0;
37803778
foreach(cur, cstate->attnumlist)
37813779
{
37823780
int attnum = lfirst_int(cur);
37833781
int m = attnum - 1;
37843782
Form_pg_attribute att = TupleDescAttr(tupDesc, m);
37853783

37863784
cstate->cur_attname = NameStr(att->attname);
3787-
i++;
37883785
values[m] = CopyReadBinaryAttribute(cstate,
3789-
i,
37903786
&in_functions[m],
37913787
typioparams[m],
37923788
att->atttypmod,
@@ -4714,8 +4710,7 @@ CopyReadAttributesCSV(CopyState cstate)
47144710
* Read a binary attribute
47154711
*/
47164712
static Datum
4717-
CopyReadBinaryAttribute(CopyState cstate,
4718-
int column_no, FmgrInfo *flinfo,
4713+
CopyReadBinaryAttribute(CopyState cstate, FmgrInfo *flinfo,
47194714
Oid typioparam, int32 typmod,
47204715
bool *isnull)
47214716
{

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy