[vdr] [PATCH] UnbufferedFile improvements v7

Artur Skawina art_k at o2.pl
Sat Feb 4 18:07:12 CET 2006


>  off_t cUnbufferedFile::Seek(off_t Offset, int Whence)
>  {
> -  if (fd >= 0)
> -     return lseek(fd, Offset, Whence);
> -  return -1;
> +  if (Whence == SEEK_SET && Offset == curpos)
> +     return curpos;
> +  curpos = lseek(fd, Offset, Whence);
> +  return curpos;
>  }

ups, missed this previously -- ignore my comment wrt to seeks...
A function call i can live with :)



More information about the vdr mailing list