git://git.onelab.eu
/
bootcd.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
This commit was generated by cvs2svn to compensate for changes in r1815,
[bootcd.git]
/
syslinux
/
com32
/
lib
/
strdup.c
diff --git a/syslinux/com32/lib/strdup.c
b/syslinux/com32/lib/strdup.c
new file mode 100644
(file)
index 0000000..
eb170c2
--- /dev/null
+++ b/
syslinux/com32/lib/strdup.c
@@ -0,0
+1,17
@@
+/*
+ * strdup.c
+ */
+
+#include <string.h>
+#include <stdlib.h>
+
+char *strdup(const char *s)
+{
+ int l = strlen(s)+1;
+ char *d = malloc(l);
+
+ if ( d )
+ memcpy(d, s, l);
+
+ return d;
+}