rem: ecasound_fiommap_buffermap[fd]->buffers[0] = (unsigned char*)mmap(0, ecasound_fiommap_buffermap[fd]->mmap_length[0], PROT_READ, MAP_SHARED, ecasound_fiommap_buffermap[fd]->fd, ecasound_fiommap_buffermap[fd]->mmap_low);
add: ecasound_fiommap_buffermap[fd]->buffers[0] = (caddr_t)mmap(0, ecasound_fiommap_buffermap[fd]->mmap_length[0], PROT_READ, MAP_SHARED, ecasound_fiommap_buffermap[fd]->fd, ecasound_fiommap_buffermap[fd]->mmap_low);
context: void ecasound_fiommap_reset(int fd, long fposition) {  //  cerr << "(eca-fileio-mmap-fthread) reset()\n";  if (ecasound_fiommap_buffermap[fd]->mmap_low != -1 &&      fposition >= ecasound_fiommap_buffermap[fd]->mmap_low &&      fposition < ecasound_fiommap_buffermap[fd]->mmap_high) return;  pthread_mutex_lock(&ecasound_fiommap_lock);  long int mmap_high = 0;  while (fposition >= mmap_high) {    mmap_high += ecasound_fiommap_buffersize;  }  ecasound_fiommap_buffermap[fd]->mmap_high = mmap_high;  ecasound_fiommap_buffermap[fd]->mmap_low =  mmap_high - ecasound_fiommap_buffersize;  munlock(ecasound_fiommap_buffermap[fd]->buffers[0], ecasound_fiommap_buffermap[fd]->mmap_length[0]);  munmap(ecasound_fiommap_buffermap[fd]->buffers[0], ecasound_fiommap_buffermap[fd]->mmap_length[0]);  if (mmap_high > ecasound_fiommap_buffermap[fd]->file_length)    ecasound_fiommap_buffermap[fd]->mmap_length[0] =      ecasound_fiommap_buffermap[fd]->file_length -      ecasound_fiommap_buffermap[fd]->mmap_low;  else    ecasound_fiommap_buffermap[fd]->mmap_length[0] = ecasound_fiommap_buffersize;    //  cerr << "(eca-fileio-mmap-fthread) mapping[s] (reset) from " << ecasound_fiommap_buffermap[fd]->mmap_low  //       << " to " << ecasound_fiommap_buffermap[fd]->mmap_low + ecasound_fiommap_buffermap[fd]->mmap_length[0] << " (fd:"  //       << ecasound_fiommap_buffermap[fd]->fd << ", buf: 0)\n";  ecasound_fiommap_buffermap[fd]->buffers[0] = (unsigned char*)mmap(0,								    ecasound_fiommap_buffermap[fd]->mmap_length[0],								    PROT_READ,								    MAP_SHARED,								    ecasound_fiommap_buffermap[fd]->fd,								    ecasound_fiommap_buffermap[fd]->mmap_low);  mlock(ecasound_fiommap_buffermap[fd]->buffers[0], ecasound_fiommap_buffermap[fd]->mmap_length[0]);  //  cerr << "(eca-fileio-mmap-fthread) mapping[f] (reset) from " << ecasound_fiommap_buffermap[fd]->mmap_low  //       << " to " << ecasound_fiommap_buffermap[fd]->mmap_high << " (fd:"  //       << ecasound_fiommap_buffermap[fd]->fd << ", buf: 0).\n";  ecasound_fiommap_buffermap[fd]->locked_buffer = 0;  ecasound_fiommap_buffermap[fd]->ready_for_fill[0] = false;  ecasound_fiommap_buffermap[fd]->ready_for_fill[1] = true;  pthread_cond_signal(&ecasound_fiommap_cond);  pthread_mutex_unlock(&ecasound_fiommap_lock);}