diff options
author | Alan Coopersmith <alan.coopersmith@oracle.com> | 2013-10-25 23:56:55 -0700 |
---|---|---|
committer | Alan Coopersmith <alan.coopersmith@oracle.com> | 2013-11-01 22:19:19 -0700 |
commit | 8a9fc31628a98e3cdaae6078bb5d92bce06c37ac (patch) | |
tree | 7c84bdff080ed227e91ca448bb58dbcdb895174a | |
parent | 8b289e10c5013cdcbf817c06bd929e3ea8339987 (diff) |
xstrdup -> strdup
Missed in xalloc -> malloc etal conversion in 0cdc9b8f850342
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Reviewed-by: Jasper St. Pierre <jstpierre@mecheye.net>
-rw-r--r-- | src/FreeType/ftfuncs.c | 4 | ||||
-rw-r--r-- | src/FreeType/xttcap.c | 20 | ||||
-rw-r--r-- | src/FreeType/xttcap.h | 9 |
3 files changed, 2 insertions, 31 deletions
diff --git a/src/FreeType/ftfuncs.c b/src/FreeType/ftfuncs.c index 918e3f3..091339d 100644 --- a/src/FreeType/ftfuncs.c +++ b/src/FreeType/ftfuncs.c @@ -2204,7 +2204,7 @@ FreeTypeSetUpTTCap( char *fileName, FontScalablePtr vals, strcpy(*dynStrRealFileName+dirLen, p2+1); capHead = p1; } else { - *dynStrRealFileName = xstrdup(fileName); + *dynStrRealFileName = strdup(fileName); if( *dynStrRealFileName == NULL ) { result = AllocError; goto quit; @@ -2549,7 +2549,7 @@ FreeTypeSetUpTTCap( char *fileName, FontScalablePtr vals, if (SPropRecValList_search_record(&listPropRecVal, &contRecValue, "CodeRange")) { - *dynStrTTCapCodeRange = xstrdup(SPropContainer_value_str(contRecValue)); + *dynStrTTCapCodeRange = strdup(SPropContainer_value_str(contRecValue)); if( *dynStrTTCapCodeRange == NULL ) { result = AllocError; goto quit; diff --git a/src/FreeType/xttcap.c b/src/FreeType/xttcap.c index bf25cc5..c1d8e67 100644 --- a/src/FreeType/xttcap.c +++ b/src/FreeType/xttcap.c @@ -682,24 +682,4 @@ SPropRecValList_add_by_font_cap(SDynPropRecValList *pThisList, return result; } - -/************************************************************************** - Functions (xttmisc) - */ - -/* strdup clone with using the allocator of X server */ -char * -XttXstrdup(char const *str) -{ - char *result; - - result = malloc(strlen(str)+1); - - if (result) - strcpy(result, str); - - return result; -} - - /* end of file */ diff --git a/src/FreeType/xttcap.h b/src/FreeType/xttcap.h index 2931098..2822540 100644 --- a/src/FreeType/xttcap.h +++ b/src/FreeType/xttcap.h @@ -116,15 +116,6 @@ SPropRecValList_dump(SRefPropRecValList *refList); #define SPropContainer_value_str(contRecVal)\ ((contRecVal)->uValue.dynStringValue) -/****************************************************** - Prototypes (xttmisc) - */ - -/* strdup clone */ -char * XttXstrdup(char const *str); -#undef xstrdup -#define xstrdup(s) XttXstrdup((char const*)s) - #endif /* !def _XTTCAP_H_ */ /* end of file */ |