FIxes additional problems found in bug #476, from chmmravatar

git-svn-id: svn://svn.code.sf.net/p/sc2/code/trunk@1235 8092fc87-c524-0410-9efc-e669fe64eaf9
This commit is contained in:
gewlitys
2003-09-15 16:38:04 +00:00
parent 814eacbe7b
commit 490108dfe6
2 changed files with 6 additions and 4 deletions
+1 -1
View File
@@ -1705,7 +1705,7 @@ DoCommunication (PENCOUNTER_STATE pES)
{ {
temp = curr->tag.data; temp = curr->tag.data;
if (temp == NULL) if (temp == NULL)
break; continue;
// fprintf (stderr, "%s\n", temp); // fprintf (stderr, "%s\n", temp);
while (wstrlen (temp) > (unsigned int) SUMMARY_CHARS while (wstrlen (temp) > (unsigned int) SUMMARY_CHARS
&& !(GLOBAL (CurrentActivity) & CHECK_ABORT)) && !(GLOBAL (CurrentActivity) & CHECK_ABORT))
+5 -3
View File
@@ -146,14 +146,16 @@ destroy_soundchain (TFB_SoundChain *chain)
TFB_SoundChain * TFB_SoundChain *
get_previous_chain (TFB_SoundChain *first_chain, TFB_SoundChain *current_chain) get_previous_chain (TFB_SoundChain *first_chain, TFB_SoundChain *current_chain)
{ {
TFB_SoundChain *prev_chain; TFB_SoundChain *prev_chain, *last_valid = NULL;
prev_chain = first_chain; prev_chain = first_chain;
if (prev_chain == current_chain) if (prev_chain == current_chain)
return (prev_chain); return (prev_chain);
while (prev_chain->next) while (prev_chain->next)
{ {
if (prev_chain->next == current_chain || !prev_chain->next->tag.data) if (prev_chain->tag.type)
return (prev_chain); last_valid = prev_chain;
if (prev_chain->next == current_chain)
return (last_valid);
prev_chain = prev_chain->next; prev_chain = prev_chain->next;
} }
return (first_chain); return (first_chain);