]> git.ipfire.org Git - thirdparty/freeswitch.git/commitdiff
remove unnecessary pool create
authorAnthony Minessale <anthm@freeswitch.org>
Tue, 8 Apr 2014 22:18:21 +0000 (03:18 +0500)
committerAnthony Minessale <anthm@freeswitch.org>
Tue, 8 Apr 2014 22:18:21 +0000 (03:18 +0500)
src/mod/languages/mod_v8/mod_v8.cpp

index 822957825b3bf5bcd99dd047849536794c2467f8..1dfb6bc83e61fc4537c0d4625e77d7cb2c8117fb 100644 (file)
@@ -827,10 +827,7 @@ SWITCH_MODULE_LOAD_FUNCTION(mod_v8_load)
                return SWITCH_STATUS_GENERR;
        }
 
-       if (switch_core_new_memory_pool(&globals.pool) != SWITCH_STATUS_SUCCESS) {
-               switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "OH OH no pool\n");
-               return SWITCH_STATUS_GENERR;
-       }
+       globals.pool = pool;
 
        switch_mutex_init(&globals.event_mutex, SWITCH_MUTEX_NESTED, globals.pool);
        globals.event_handlers = new set<FSEventHandler *>();
@@ -873,7 +870,6 @@ SWITCH_MODULE_SHUTDOWN_FUNCTION(mod_v8_shutdown)
 
        delete globals.event_handlers;
        switch_mutex_destroy(globals.event_mutex);
-       switch_core_destroy_memory_pool(&globals.pool);
 
        switch_core_hash_destroy(&module_manager.load_hash);