Re: Re: patch for src/backend/main/main.c - Mailing list pgsql-patches

From Alfred Perlstein
Subject Re: Re: patch for src/backend/main/main.c
Date
Msg-id 20010123174728.P26076@fw.wintelcom.net
Whole thread Raw
In response to Re: patch for src/backend/main/main.c  ("Michael C. Thornburgh" <zenomt@armory.com>)
Responses Re: Re: patch for src/backend/main/main.ch  (Bruce Momjian <pgman@candle.pha.pa.us>)
List pgsql-patches
* Michael C. Thornburgh <zenomt@armory.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@wintelcom.net|alfred@freebsd.org]
"I have the heart of a child; I keep it in a jar on my desk."

pgsql-patches by date:

Previous
From: Bruce Momjian
Date:
Subject: Re: Re: patch for src/backend/main/main.c
Next
From: Bruce Momjian
Date:
Subject: Re: Re: patch for src/backend/main/main.ch