Cygwin: clipboard: Only SEEK_SET and SEEK_CUR are supported
Make sure of that, especially given the addition of SEEK_DATA and SEEK_HOLE. Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
This commit is contained in:
parent
07092a52e9
commit
5b53633b5d
|
@ -322,6 +322,13 @@ fhandler_dev_clipboard::lseek (off_t offset, int whence)
|
|||
* On writes we use this to decide how to write - empty and write, or open, copy, empty
|
||||
* and write
|
||||
*/
|
||||
if (whence == SEEK_CUR)
|
||||
return 0;
|
||||
if (whence != SEEK_SET)
|
||||
{
|
||||
set_errno (EINVAL);
|
||||
return -1;
|
||||
}
|
||||
pos = offset;
|
||||
/* treat seek like rewind */
|
||||
if (membuffer)
|
||||
|
|
Loading…
Reference in New Issue