Re: Faster StrNCpy - Mailing list pgsql-hackers

From Tom Lane
Subject Re: Faster StrNCpy
Date
Msg-id 29984.1159305145@sss.pgh.pa.us
Whole thread Raw
In response to Re: Faster StrNCpy  (Neil Conway <neilc@samurai.com>)
Responses Re: Faster StrNCpy  (Josh Berkus <josh@agliodbs.com>)
Re: Faster StrNCpy  (Bruce Momjian <bruce@momjian.us>)
List pgsql-hackers
Neil Conway <neilc@samurai.com> writes:
> A wholesale replacement of strncpy() calls is probably worth doing --
> replacing them with strlcpy() if the source string is NUL-terminated,
> and I suppose memcpy() otherwise.

What I'd like to do immediately is put in strlcpy() and hit the two or
three places I think are performance-relevant.  I agree with trying to
get rid of StrNCpy/strncpy calls over the long run, but it's just code
beautification and probably not appropriate for beta.
        regards, tom lane


pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: Faster StrNCpy
Next
From: "luis garcia"
Date:
Subject: Constant changes (Re-Build)