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:
authorDaniel Dunbar <daniel@zuster.org>2003-03-25 18:54:46 +0300
committerDaniel Dunbar <daniel@zuster.org>2003-03-25 18:54:46 +0300
commitcdb2974b672e5cd9e1262f85b78d8d9fff1d0741 (patch)
tree87559b8bbf722f811377fd6c4911ddbd8be73ed6 /source/blender/blenloader
parentdbb49fd37853abe07bd09a70465e6098f36ecaf6 (diff)
Fix for bug #70.
I am a little skeptical about this patch, because somehow the file had the TXT_ISEXT flag set in it, and the support for that feature isn't complete. What I want to know is how that flag got set in the first place, none of the interface code turns it on. At least it fixes the crash.
Diffstat (limited to 'source/blender/blenloader')
-rw-r--r--source/blender/blenloader/intern/readfile.c42
1 files changed, 20 insertions, 22 deletions
diff --git a/source/blender/blenloader/intern/readfile.c b/source/blender/blenloader/intern/readfile.c
index 07d7c7fcc5a..b87b4d11695 100644
--- a/source/blender/blenloader/intern/readfile.c
+++ b/source/blender/blenloader/intern/readfile.c
@@ -1661,33 +1661,31 @@ static void direct_link_text(FileData *fd, Text *text)
text->compiled= NULL;
+/*
if(text->flags & TXT_ISEXT) {
- /* not implemented yet... */
- /* reopen_text(text); */
+ reopen_text(text);
} else {
+*/
- if(text->lines.first==0) return;
-
- link_list(fd, &text->lines);
-
- text->curl= newdataadr(fd, text->curl);
- text->sell= newdataadr(fd, text->sell);
-
- ln= text->lines.first;
- while(ln) {
- ln->line= newdataadr(fd, ln->line);
-
- if (ln->len != (int) strlen(ln->line)) {
- printf("Error loading text, line lengths differ\n");
- ln->len = strlen(ln->line);
- }
-
- ln= ln->next;
+ link_list(fd, &text->lines);
+
+ text->curl= newdataadr(fd, text->curl);
+ text->sell= newdataadr(fd, text->sell);
+
+ ln= text->lines.first;
+ while(ln) {
+ ln->line= newdataadr(fd, ln->line);
+
+ if (ln->len != (int) strlen(ln->line)) {
+ printf("Error loading text, line lengths differ\n");
+ ln->len = strlen(ln->line);
}
-
- text->flags |= TXT_ISTMP;
+
+ ln= ln->next;
}
-
+
+ text->flags = (text->flags|TXT_ISTMP) & ~TXT_ISEXT;
+
text->id.us= 1;
}