Re: [HACKERS] version functions (was NT port of PGSQL - success)

From: jwieck(at)debis(dot)com (Jan Wieck)
To: jhickey(at)impact1(dot)hpcc(dot)nectec(dot)or(dot)th (Justin Hickey)
Cc: maillist(at)candle(dot)pha(dot)pa(dot)us, pgsql-hackers(at)hub(dot)org
Subject: Re: [HACKERS] version functions (was NT port of PGSQL - success)
Date: 1998-10-09 10:05:48
Message-ID: m0zRZQi-000EBPC@orion.SAPserv.Hamburg.dsh.de
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Jazzman wrote:
>
> Hello Bruce
>
> On Oct 8, 5:40pm, Bruce Momjian wrote:
> > I have removed the data/base/*/pg_version file because it was never
> > used. We had removed the 'version' functions long ago, but
> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>
> Does this mean that the following from the FAQ is wrong?
>
> 3.25) How do I tell what PostgreSQL version I am running?
>
> From psql, type select version();
>
> If so then this question should probably be changed to point users to the
> PG_VERSION file.

No, it is still correct. The version function is there and it
returns the compiled in string from version.h.

But take a look at version.c please. I think it should use
memcpy() or strncpy() instead of strcpy(). As it is now it
writes the null byte after the palloc'ed area.

Jan

--

#======================================================================#
# It's easier to get forgiveness for being wrong than for being right. #
# Let's break this rule - forgive me. #
#======================================== jwieck(at)debis(dot)com (Jan Wieck) #

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Horak Daniel 1998-10-09 11:15:01 RE: [HACKERS] NT port of PGSQL - success
Previous Message Justin Hickey 1998-10-09 09:07:23 Re: [HACKERS] version functions (was NT port of PGSQL - success)