mirror of
https://github.com/postgres/postgres.git
synced 2025-06-30 21:42:05 +03:00
Fix pgproc names over 15 chars in output. Add strNcpy() function. remove some (void) casts that are unnecessary.
This commit is contained in:
@ -7,7 +7,7 @@
|
||||
*
|
||||
*
|
||||
* IDENTIFICATION
|
||||
* $Header: /cvsroot/pgsql/src/backend/parser/analyze.c,v 1.30 1997/08/03 02:35:28 momjian Exp $
|
||||
* $Header: /cvsroot/pgsql/src/backend/parser/analyze.c,v 1.31 1997/08/12 20:15:31 momjian Exp $
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
@ -1004,8 +1004,7 @@ makeTargetNames(ParseState *pstate, List *cols)
|
||||
Ident *id = makeNode(Ident);
|
||||
|
||||
id->name = palloc(NAMEDATALEN);
|
||||
strncpy(id->name, attr[i]->attname.data, NAMEDATALEN);
|
||||
id->name[NAMEDATALEN-1]='\0';
|
||||
strNcpy(id->name, attr[i]->attname.data, NAMEDATALEN-1);
|
||||
id->indirection = NIL;
|
||||
id->isRel = false;
|
||||
if (tl == NIL)
|
||||
|
Reference in New Issue
Block a user