+ if (end - start > count)
+ {
+ end = lseek (file->priv->fd, count - (end - start), SEEK_CUR);
+ if (end == -1)
+ {
+ int errsv = errno;
+
+ g_set_error (error, G_IO_ERROR,
+ g_io_error_from_errno (errsv),
+ _("Error seeking in file: %s"),
+ g_strerror (errsv));
+ return -1;
+ }
+ }
+
+ return end - start;