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:
Diffstat (limited to 'source/blender')
-rw-r--r--source/blender/windowmanager/intern/wm_files.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/source/blender/windowmanager/intern/wm_files.c b/source/blender/windowmanager/intern/wm_files.c
index 6f44ce8934d..f6e5263e483 100644
--- a/source/blender/windowmanager/intern/wm_files.c
+++ b/source/blender/windowmanager/intern/wm_files.c
@@ -374,11 +374,11 @@ void read_Blog(void)
G.recent_files.first = G.recent_files.last = NULL;
/* read list of recent opend files from .Blog to memory */
- for (l= lines, num= 0; l && (num<U.recent_files); l= l->next, num++) {
+ for (l= lines, num= 0; l && (num<U.recent_files); l= l->next) {
line = l->link;
- if (!BLI_streq(line, "")) {
+ if (line[0] && BLI_exists(line)) {
if (num==0)
- strcpy(G.sce, line);
+ strcpy(G.sce, line); /* note: this seems highly dodgy since the file isnt actually read. please explain. - campbell */
recent = (RecentFile*)MEM_mallocN(sizeof(RecentFile),"RecentFile");
BLI_addtail(&(G.recent_files), recent);
@@ -386,6 +386,7 @@ void read_Blog(void)
recent->filename[0] = '\0';
strcpy(recent->filename, line);
+ num++;
}
}