mirror of
https://github.com/tbamud/tbamud.git
synced 2025-12-23 18:50:13 +01:00
Fixed off-by-one bug in loop, illogical negation. - thanks for the bug report, Halenbane.
This commit is contained in:
parent
ebfc7ce54b
commit
bc786ae015
1 changed files with 2 additions and 2 deletions
|
|
@ -455,12 +455,12 @@ void script_syntax_highlighting(struct descriptor_data *d, char *string)
|
||||||
// Highlight lines
|
// Highlight lines
|
||||||
if (!comment) {
|
if (!comment) {
|
||||||
// Syntax replacement
|
// Syntax replacement
|
||||||
for (i=0;i <= SYNTAX_TERMS;i++) {
|
for (i=0;i < SYNTAX_TERMS;i++) {
|
||||||
line = str_replace(line, syntax_color_replacement[i][0], syntax_color_replacement[i][1]);
|
line = str_replace(line, syntax_color_replacement[i][0], syntax_color_replacement[i][1]);
|
||||||
}
|
}
|
||||||
|
|
||||||
// Commands replacement
|
// Commands replacement
|
||||||
for (i=0;i <= COMMAND_TERMS;i++) {
|
for (i=0;i < COMMAND_TERMS;i++) {
|
||||||
line = str_replace(line, command_color_replacement[i][0], command_color_replacement[i][1]);
|
line = str_replace(line, command_color_replacement[i][0], command_color_replacement[i][1]);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue