last_read_sector = requested_sector_end;
}
+ index = ra_sector % SECTOR_BUFFER_SIZE;
+
// check for end of CD
if (ra_count && ra_sector >= max_sector) {
ra_count = 0;
+ pthread_mutex_lock(§orbuffer_lock);
+ sectorbuffer[index].ret = -1;
+ sectorbuffer[index].sector = ra_sector;
+ pthread_cond_signal(§orbuffer_cond);
+ pthread_mutex_unlock(§orbuffer_lock);
}
if (ra_count) {
-
- index = ra_sector % SECTOR_BUFFER_SIZE;
pthread_mutex_lock(§orbuffer_lock);
if (sectorbuffer[index].sector != ra_sector) {
pthread_mutex_unlock(§orbuffer_lock);