Path: utzoo!utgpu!water!watmath!clyde!att!pacbell!ames!umd5!cvl!elsie!ado From: ado@elsie.UUCP (Arthur David Olson) Newsgroups: comp.std.c Subject: Re: char *strcat(), *strcpy(), *fgets(); Summary: Ahem. . . Message-ID: <8099@elsie.UUCP> Date: 26 Jun 88 18:06:18 GMT References: <1309@ark.cs.vu.nl> <11580010@hpisod2.HP.COM> <8160@brl-smoke.ARPA> Organization: NIH-LEC, Bethesda, MD Lines: 19 In article <8160@brl-smoke.ARPA>, gwyn@brl-smoke.ARPA (Doug Gwyn ) writes: < In article <11580010@hpisod2.HP.COM> decot@hpisod2.HP.COM (Dave Decot) writes: < >... there's nothing to prevent adding more useful functions: < > [strecpy, strecat, strlcpy, strlcat] < < Those are indeed useful, but probably the names should not start with "str", < to avoid conflicts with possible revisions of the C standard. While in article <8148@brl-smoke.ARPA>, gwyn@brl-smoke.ARPA (Doug Gwyn ) writes: < In article <2030@pt.cs.cmu.edu> jgm@k.gp.cs.cmu.edu (John Myers) writes: < >#define SAVESTR(s) (strcpy(malloc(strlen(s)+1),(s))) < < Most of us call this function strdup(). . . Well. . .strdup is indeed useful, but probably the name should not start with "str", to avoid conflicts with possible revisions of the C standard. (Here at elsie we call it "icpyalloc", but then again we're not "most of us.") -- ado@ncifcrf.gov ADO is a trademark of Ampex.