ref: 7c88dc7a0c96e24b53b0aeea66d74b3a757be2d4 dir: /lib/xstrdup.c/
#include <string.h> #include <cc.h> char * xstrdup(const char *s) { register size_t len = strlen(s) + 1; register char *p = xmalloc(len); return memcpy(p, s, len); }