Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCampbell Barton <ideasman42@gmail.com>2019-02-24 04:47:48 +0300
committerCampbell Barton <ideasman42@gmail.com>2019-02-24 04:47:48 +0300
commit6bab905c9d40a1cdddd15701cd3364534eae0a87 (patch)
tree7e506342eddcfda157608163ee2cbb71b33f9f45 /source/blender/blenloader
parent8ed82e82e6a29461cbf2836fbbe7ca2f0557cc6e (diff)
readfile: Disable delayed data reading for compressed blend files
Seeking gzip files is very slow, disable it. Resolves T61880
Diffstat (limited to 'source/blender/blenloader')
-rw-r--r--source/blender/blenloader/intern/readfile.c8
1 files changed, 1 insertions, 7 deletions
diff --git a/source/blender/blenloader/intern/readfile.c b/source/blender/blenloader/intern/readfile.c
index b04fa5d433e..6fc96c88d2d 100644
--- a/source/blender/blenloader/intern/readfile.c
+++ b/source/blender/blenloader/intern/readfile.c
@@ -1156,12 +1156,6 @@ static int fd_read_gzip_from_file(FileData *filedata, void *buffer, uint size)
return (readsize);
}
-static off_t fd_seek_gzip_from_file(FileData *filedata, off_t offset, int whence)
-{
- filedata->file_offset = gzseek(filedata->gzfiledes, offset, whence);
- return filedata->file_offset;
-}
-
/* Memory reading. */
static int fd_read_from_memory(FileData *filedata, void *buffer, uint size)
@@ -1328,8 +1322,8 @@ static FileData *blo_filedata_from_file_open(const char *filepath, ReportList *r
return NULL;
}
else {
+ /* 'seek_fn' is too slow for gzip, don't set it. */
read_fn = fd_read_gzip_from_file;
- seek_fn = fd_seek_gzip_from_file;
}
}