a
This commit is contained in:
14
libc/runestrdup.c
Normal file
14
libc/runestrdup.c
Normal file
@ -0,0 +1,14 @@
|
||||
#include <u.h>
|
||||
#include <libc.h>
|
||||
|
||||
Rune*
|
||||
runestrdup(Rune *s)
|
||||
{
|
||||
Rune *ns;
|
||||
|
||||
ns = malloc(sizeof(Rune)*(runestrlen(s) + 1));
|
||||
if(ns == 0)
|
||||
return 0;
|
||||
|
||||
return runestrcpy(ns, s);
|
||||
}
|
Reference in New Issue
Block a user