From 21cbb8bb6832b87a3fe1dcc915c0ac69a9a7c73a Mon Sep 17 00:00:00 2001 From: russell Date: Thu, 19 Oct 2006 01:00:57 +0000 Subject: Extend the thread storage API such that a custom initialization function can be called for each thread specific object after they are allocated. Note that there was already the ability to define a custom cleanup function. Also, if the custom cleanup function is used, it *MUST* call free on the thread specific object at the end. There is no way to have this magically done that I can think of because the cleanup function registered with the pthread implementation will only call the function back with a pointer to the thread specific object, not the parent ast_threadstorage object. git-svn-id: http://svn.digium.com/svn/asterisk/trunk@45623 f38db490-d61c-443f-a65b-d21fe96a405b --- channels/iax2-parser.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'channels/iax2-parser.c') diff --git a/channels/iax2-parser.c b/channels/iax2-parser.c index 0a524e253..09e04c432 100644 --- a/channels/iax2-parser.c +++ b/channels/iax2-parser.c @@ -53,7 +53,7 @@ static int oframes = 0; static void frame_cache_cleanup(void *data); /*! \brief A per-thread cache of iax_frame structures */ -AST_THREADSTORAGE_CUSTOM(frame_cache, frame_cache_init, frame_cache_cleanup); +AST_THREADSTORAGE_CUSTOM(frame_cache, NULL, frame_cache_cleanup); /*! \brief This is just so iax_frames, a list head struct for holding a list of * iax_frame structures, is defined. */ -- cgit v1.2.3