Commit 14834564 authored by Bruce Momjian's avatar Bruce Momjian

Fix for version() string overwrite.

parent d12d4c78
......@@ -5,7 +5,7 @@
*
* IDENTIFICATION
*
* $Header: /cvsroot/pgsql/src/backend/utils/adt/version.c,v 1.2 1998/09/01 04:32:55 momjian Exp $
* $Header: /cvsroot/pgsql/src/backend/utils/adt/version.c,v 1.3 1998/10/09 16:42:32 momjian Exp $
*
*-------------------------------------------------------------------------
*/
......@@ -23,7 +23,7 @@ version(void)
text *ret = (text *) palloc(n);
VARSIZE(ret) = n;
strcpy(VARDATA(ret), PG_VERSION_STR);
StrNCpy(VARDATA(ret), PG_VERSION_STR, strlen(PG_VERSION_STR));
return ret;
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment