There's an old BYOND bug in which sometimes system text (like a crash or pager message) would print in the text output and the font would change. Another issue, possibly related, had to do with margins not resetting properly at times. I don't know if they're the same bug, but I think I may have found the first one, and it's ancient. It all has to do with linked lists. BYOND uses linked lists all over the place, and one of those uses is to keep track of stylesheets it has parsed. To properly apply a stylesheet, it has to clear out all the old style rules first.
void StyleParser::ClipRules(int origin) { StyleRule *r = ruleL; StyleRule **rp = &ruleL; while(r) { if(r->origin == origin) { *rp = r->next; r->next = NULL; delete r; if(!*rp) break; r = (*rp)->next; } else { rp = &r->next; r = r->next; } } }
The error occurs on only one line, and I'll give you this hint: When all of the rules needed to be removed, sometimes they would be fully removed, sometimes not. (I found it because in one case it would alternate between working fully and working partially.) So, who wants to guess which line had to be changed, and how?