Commit 866b12ec authored by Jean-Baptiste Kempf's avatar Jean-Baptiste Kempf

Fix data race condition accessing this->cur_cell_time

parent 42403a82
......@@ -1288,12 +1288,12 @@ dvdnav_status_t dvdnav_jump_to_sector_by_time(dvdnav_t *this,
/* jump to sector */
sector_off = jump->sector - cell_data->bgn->sector;
result = vm_jump_cell_block(this->vm, cell_data->idx, sector_off);
pthread_mutex_lock(&this->vm_lock);
this->cur_cell_time = 0;
if (result) {
pthread_mutex_lock(&this->vm_lock);
if (result) { /* vm_jump_cell_block was sucessful */
this->vm->hop_channel += HOP_SEEK;
pthread_mutex_unlock(&this->vm_lock);
}
pthread_mutex_unlock(&this->vm_lock);
exit:
return result;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment