Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

Commit 89c7e18

Browse files
author
Bryan Henderson
committed
Forgot in yesterday's Ultrix compile work.
1 parent 8cfe27d commit 89c7e18

File tree

1 file changed

+24
-0
lines changed

1 file changed

+24
-0
lines changed

src/utils/strdup.c

+24
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
/*-------------------------------------------------------------------------
2+
*
3+
* strdup.c--
4+
* copies a null-terminated string.
5+
*
6+
* Copyright (c) 1994, Regents of the University of California
7+
*
8+
*
9+
* IDENTIFICATION
10+
* $Header: /cvsroot/pgsql/src/utils/Attic/strdup.c,v 1.1 1996/11/27 01:46:52 bryanh Exp $
11+
*
12+
*-------------------------------------------------------------------------
13+
*/
14+
#include <string.h>
15+
#include "strdup.h"
16+
17+
char *
18+
strdup(char *string)
19+
{
20+
char *nstr;
21+
22+
nstr = strcpy((char *)palloc(strlen(string)+1), string);
23+
return nstr;
24+
}

0 commit comments

Comments
 (0)