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

Commit8bac4ca

Browse files
committed
Rename libpq to use more normal field names.
1 parent6ce9c76 commit8bac4ca

File tree

2 files changed

+11
-11
lines changed

2 files changed

+11
-11
lines changed

‎src/interfaces/libpq/fe-exec.c

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
*
88
*
99
* IDENTIFICATION
10-
* $Header: /cvsroot/pgsql/src/interfaces/libpq/fe-exec.c,v 1.57 1998/07/1300:01:44 momjian Exp $
10+
* $Header: /cvsroot/pgsql/src/interfaces/libpq/fe-exec.c,v 1.58 1998/07/1302:41:58 momjian Exp $
1111
*
1212
*-------------------------------------------------------------------------
1313
*/
@@ -498,21 +498,21 @@ getRowDescriptions(PGconn *conn)
498498
{
499499
chartypName[MAX_MESSAGE_LEN];
500500
intadtid;
501-
intadtsize;
502-
intadtmod=-1;
501+
inttyplen;
502+
intatttypmod=-1;
503503

504504
if (pqGets(typName,MAX_MESSAGE_LEN,conn)||
505505
pqGetInt(&adtid,4,conn)||
506-
pqGetInt(&adtsize,2,conn)||
507-
pqGetInt(&adtmod,4,conn))
506+
pqGetInt(&typlen,2,conn)||
507+
pqGetInt(&atttypmod,4,conn))
508508
{
509509
PQclear(result);
510510
returnEOF;
511511
}
512512
result->attDescs[i].name=strdup(typName);
513513
result->attDescs[i].adtid=adtid;
514-
result->attDescs[i].adtsize= (short)adtsize;
515-
result->attDescs[i].adtmod=adtmod;
514+
result->attDescs[i].typlen= (short)typlen;
515+
result->attDescs[i].atttypmod=atttypmod;
516516
}
517517

518518
/* Success! */
@@ -1294,7 +1294,7 @@ PQfsize(PGresult *res, int field_num)
12941294
return0;
12951295
}
12961296
if (res->attDescs)
1297-
returnres->attDescs[field_num].adtsize;
1297+
returnres->attDescs[field_num].typlen;
12981298
else
12991299
return0;
13001300
}
@@ -1316,7 +1316,7 @@ PQfmod(PGresult *res, int field_num)
13161316
return0;
13171317
}
13181318
if (res->attDescs)
1319-
returnres->attDescs[field_num].adtmod;
1319+
returnres->attDescs[field_num].atttypmod;
13201320
else
13211321
return0;
13221322
}

‎src/interfaces/libpq/libpq-fe.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: libpq-fe.h,v 1.32 1998/07/1300:01:45 momjian Exp $
9+
* $Id: libpq-fe.h,v 1.33 1998/07/1302:41:59 momjian Exp $
1010
*
1111
*-------------------------------------------------------------------------
1212
*/
@@ -78,7 +78,7 @@ extern"C"
7878
char*name;/* type name */
7979
Oidadtid;/* type id */
8080
shortadtsize;/* type size */
81-
intadtmod;/* type-specific modifier info */
81+
intatttypmod;/* type-specific modifier info */
8282
}PGresAttDesc;
8383

8484
/* use char* for Attribute values,

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp