diff options
author | Eric S. Raymond <esr@thyrsus.com> | 1996-10-15 14:48:34 +0000 |
---|---|---|
committer | Eric S. Raymond <esr@thyrsus.com> | 1996-10-15 14:48:34 +0000 |
commit | 4c2423a98542de4ab80ff75cb5987aa59f788ee1 (patch) | |
tree | e27ebc534bd4815c5b51ecf8f35f4640336d7c17 /xmalloc.c | |
parent | c1e1a25354f0072bf6bb871361f0316ed4e90593 (diff) | |
download | fetchmail-4c2423a98542de4ab80ff75cb5987aa59f788ee1.tar.gz fetchmail-4c2423a98542de4ab80ff75cb5987aa59f788ee1.tar.bz2 fetchmail-4c2423a98542de4ab80ff75cb5987aa59f788ee1.zip |
Simplify the autoconfig process a lot.
svn path=/trunk/; revision=337
Diffstat (limited to 'xmalloc.c')
-rw-r--r-- | xmalloc.c | 12 |
1 files changed, 11 insertions, 1 deletions
@@ -13,6 +13,7 @@ #include <config.h> #include <stdio.h> +#include <string.h> #include <sys/types.h> #include "fetchmail.h" @@ -24,7 +25,7 @@ XMALLOCTYPE * xmalloc (n) -size_t n; +int n; { XMALLOCTYPE *p; @@ -35,3 +36,12 @@ size_t n; } return(p); } + +char *xstrdup(s) +char *s; +{ + char *p; + p = (char *) xmalloc(strlen(s)+1); + strcpy(p,s); + return p; +} |