|
--- malloc.c.orig Tue Jun 10 14:55:53 2003
+++ malloc.c Wed Jun 18 16:45:34 2003
@@ -937,18 +937,18 @@
* xalloc_b -> If set to 1 then print an error and exit if we run out
* of memory.
*/
-DMALLOC_PNT dmalloc_strdup(const char *file, const int line,
+char * dmalloc_strdup(const char *file, const int line,
const char *string, const int xalloc_b)
{
DMALLOC_SIZE len;
- DMALLOC_PNT *new_string;
+ char *new_string;
len = strlen(string) + 1;
new_string = dmalloc_malloc(file, line, len, DMALLOC_FUNC_STRDUP,
0 /* no alignment */, xalloc_b);
if (new_string != NULL) {
- strncpy((char *)new_string, string, len - 1);
+ strncpy(new_string, string, len - 1);
new_string[len - 1] = '\0';
}
|