casper....@sun.com wrote: > > > char buf[] = "foo"; > > strcpy(buf+3, buf); > > It's clearly not useful.
OK, but this is a well known case that nobody should be interested in. > You want this to work: > > char buf[] = "foo\\abaz""; > > strcpy(buf+4, buf+5); /* Remove "\" at position 4. */ This is the typical use case for overlapping strings. Jörg -- EMail:jo...@schily.isdn.cs.tu-berlin.de (home) Jörg Schilling D-13353 Berlin j...@cs.tu-berlin.de (uni) joerg.schill...@fokus.fraunhofer.de (work) Blog: http://schily.blogspot.com/ URL: http://cdrecord.berlios.de/private/ ftp://ftp.berlios.de/pub/schily _______________________________________________ opensolaris-code mailing list opensolaris-code@opensolaris.org http://mail.opensolaris.org/mailman/listinfo/opensolaris-code