strcpy

Neal Weidenhofer nw at amdahl.uts.amdahl.com
Fri Apr 8 11:24:17 AEST 1988


In article <137 at polygen.UUCP>, pablo at polygen.uucp (Pablo Halpern) writes:
>        To avoid incorrect inferences from readers, the entry should
> be revised to just say that the copy INCLUDES the NUL terminator.
> 
> Pablo Halpern		|	mit-eddie \
> Polygen Corp.		|	princeton  \ !polygen!pablo  (UUCP)
> 200 Fifth Ave.		|	bu-cs      /
> Waltham, MA 02254	|	stellar   /

In dpANS Section 4.11.2.3 the description is:

The |strcpy| function copies the string pointed to by |s2|
(including the terminating null character) into the array
pointed to by |s1|.  If copying takes place between objects that
overlap, the behavior is undefined.

The opinions expressed above are mine (but I'm willing to share.)

Sometimes I live	Regards,
	in the country		Neal Weidenhofer
Sometimes I live		...{hplabs|ihnp4|ames|decwrl}!amdahl!nw
	in town			Amdahl Corporation
Sometimes I take		1250 E. Arques Ave. (M/S 316)
	a great notion		P. O. Box 3470
To jump in the river		Sunnyvale, CA 94088-3470
	and drown		(408)737-5007



More information about the Comp.lang.c mailing list