Ticket #4736: tss-mingw-2010-10-14.patch

File tss-mingw-2010-10-14.patch, 791 bytes (added by Jim Bell <jim@…>, 12 years ago)
  • libs/thread/src/win32/thread.cpp

     
    586586            else
    587587            {
    588588                detail::thread_data_base* const current_thread_data(get_or_make_current_thread_data());
    589                 tss_data_node* const new_node=heap_new<tss_data_node>(key,func,tss_data,current_thread_data->tss_data);
    590                 current_thread_data->tss_data=new_node;
     589                                if (current_thread_data)
     590                                        {
     591                                        tss_data_node* const new_node=heap_new<tss_data_node>(key,func,tss_data,current_thread_data->tss_data);
     592                                        current_thread_data->tss_data=new_node;
     593                                        }
    591594            }
    592595        }
    593596    }