mirror of
https://github.com/signalwire/freeswitch.git
synced 2025-03-13 12:40:17 +00:00
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@224 d0543943-73ff-0310-b7d9-9358b9ac24b2
This commit is contained in:
parent
d5eaa0bdc9
commit
be19275578
@ -526,6 +526,8 @@ SWITCH_DECLARE(char *) switch_core_permenant_strdup(char *todup)
|
||||
|
||||
assert(runtime.memory_pool != NULL);
|
||||
|
||||
if (!todup) return NULL;
|
||||
|
||||
len = strlen(todup) + 1;
|
||||
if (todup && (duped = apr_palloc(runtime.memory_pool, len))) {
|
||||
strncpy(duped, todup, len);
|
||||
@ -541,6 +543,8 @@ SWITCH_DECLARE(char *) switch_core_session_strdup(switch_core_session *session,
|
||||
assert(session != NULL);
|
||||
assert(session->pool != NULL);
|
||||
|
||||
if (!todup) return NULL;
|
||||
|
||||
len = strlen(todup) + 1;
|
||||
|
||||
if (todup && (duped = apr_palloc(session->pool, len))) {
|
||||
@ -557,6 +561,7 @@ SWITCH_DECLARE(char *) switch_core_strdup(switch_memory_pool *pool, char *todup)
|
||||
assert(pool != NULL);
|
||||
assert(todup != NULL);
|
||||
|
||||
if (!todup) return NULL;
|
||||
len = strlen(todup) + 1;
|
||||
|
||||
if (todup && (duped = apr_palloc(pool, len))) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user