ref: 4698e1692871826efbc031b0d2c9991ea8ee6be5 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); }