• Marko Mäkelä's avatar
    MDEV-28689, MDEV-28690: Incorrect error handling for ctrl_mutex · 863c3eda
    Marko Mäkelä authored
    comp_thread_ctxt_t: Remove ctrl_mutex, ctrl_cond, started. We do not
    actually need them for anything.
    
    destroy_worker_thread(): Split from destroy_worker_threads().
    
    create_worker_threads(): We already initialize
    thd->data_avail=FALSE and thd->cancelled=FALSE before
    invoking pthread_create(). If any thread creation fails,
    clean up by destroy_worker_thread().
    
    compress_worker_thread_func(): Assume that thd->started and
    thd->data_avail are already initialized.
    
    Reviewed by: Vladislav Vaintroub
    863c3eda
ds_compress.cc 10.1 KB