Skip site navigation (1) Skip section navigation (2)

Re: Re: patch for src/backend/main/main.c

From: Alfred Perlstein <bright(at)wintelcom(dot)net>
To: "Michael C(dot) Thornburgh" <zenomt(at)armory(dot)com>
Cc: tgl(at)sss(dot)pgh(dot)pa(dot)us, pgsql-patches(at)postgresql(dot)org
Subject: Re: Re: patch for src/backend/main/main.c
Date: 2001-01-24 01:47:29
Message-ID: 20010123174728.P26076@fw.wintelcom.net (view raw or flat)
Thread:
Lists: pgsql-patches
* Michael C. Thornburgh <zenomt(at)armory(dot)com> [010123 17:33] wrote:
> 
> that certainly works and is much cleaner, but strdup
> may not be as ubiquitous as malloc & strncpy.
> someone more versed in portability issues than i am
> should speak to that.

hmm:

HISTORY
     The strdup() function first appeared in 4.4BSD.

however:

http://www.abisource.com/mailinglists/abiword-dev/99/March/0038.html

  "strdup is no in the ANSI standard"

however:

~/pgcvs % find . -name "*.c" | xargs grep strdup | grep -v pstrdup | wc -l
     563

  (pstrdup() seems to be some internal postgresql function.)

So I think anyone who wants to port should provide thier own
function.

-- 
-Alfred Perlstein - [bright(at)wintelcom(dot)net|alfred(at)freebsd(dot)org]
"I have the heart of a child; I keep it in a jar on my desk."

In response to

Responses

pgsql-patches by date

Next:From: Bruce MomjianDate: 2001-01-24 01:51:17
Subject: Re: Re: patch for src/backend/main/main.ch
Previous:From: Bruce MomjianDate: 2001-01-24 01:38:38
Subject: Re: Re: patch for src/backend/main/main.c

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group