Take advantage of the easier-to-use thread macros
authorDerrell Lipman <derrell@dworkin.(none)>
Wed, 13 May 2009 18:33:21 +0000 (14:33 -0400)
committerDerrell Lipman <derrell@dworkin.(none)>
Wed, 13 May 2009 18:37:28 +0000 (14:37 -0400)
- Now that we initialize for the non-thread-safe case in the macro, there's no
  need to do it here too.

Derrell

lib/util/talloc_stack.c

index f1727ce469d87594d20061c9b925234daa9abf94..596efbf6cd36ab1e72748e12cf1f1e5e1d954c23 100644 (file)
@@ -60,14 +60,6 @@ static smb_thread_once_t ts_initialized = SMB_THREAD_ONCE_INIT;
 
 static void talloc_stackframe_init(void * unused)
 {
-       if (!global_tfp) {
-               /* Non-thread safe init case. */
-               if (SMB_THREAD_ONCE_IS_INITIALIZED(ts_initialized)) {
-                       return;
-               }
-               SMB_THREAD_ONCE_INITIALIZE(ts_initialized);
-       }
-
        if (SMB_THREAD_CREATE_TLS("talloc_stackframe", global_ts)) {
                smb_panic("talloc_stackframe_init create_tls failed");
        }