home *** CD-ROM | disk | FTP | other *** search
- @node strdup, string
- @subheading Syntax
-
- @example
- #include <string.h>
-
- char * strdup (const char *source);
- @end example
-
- @subheading Description
-
- Returns a newly allocated area of memory that contains a duplicate of
- the string pointed to by @var{source}. The memory returned by this
- call must be freed by the caller.
-
- @subheading Return Value
-
- Returns the newly allocated string, or @var{NULL} if there
- is no more memory.
-
- @subheading Example
-
- @example
- char *foo()
- @{
- return strdup("hello");
- @}
- @end example
-
-