This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: patch to clean out savestring, copystr, mybzero and mybcopy


ghazi@caip.rutgers.edu (Kaveh R. Ghazi) writes:

> BTW, the canonical xstrdup in libiberty itself used strcpy.  Someday
> when we resolve the host vs build issue in libiberty, all of these
> definitions of xstrdup will go away and we'll just get it from
> libiberty.a. 

This is because memcpy was at least in the older days not generally
available.  So to avoid requiring a check whether bcopy or memcpy is
available the easiest route was chosen: using strcpy.

-- 
---------------.      drepper at gnu.org  ,-.   1325 Chesapeake Terrace
Ulrich Drepper  \    ,-------------------'   \  Sunnyvale, CA 94089 USA
Cygnus Solutions `--' drepper at cygnus.com   `------------------------


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]