1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2025-12-21 13:10:37 -08:00

* coding.c (encode_coding_raw_text): Avoid unnecessary test

the first time through the loop, since we know p0 < p1 then.
This also avoids a gcc -Wstrict-overflow warning.
This commit is contained in:
Paul Eggert 2011-03-22 09:20:45 -07:00
parent a2d2666036
commit 8abc3f1295
2 changed files with 6 additions and 1 deletions

View file

@ -5266,11 +5266,12 @@ encode_coding_raw_text (struct coding_system *coding)
unsigned char str[MAX_MULTIBYTE_LENGTH], *p0 = str, *p1 = str;
CHAR_STRING_ADVANCE (c, p1);
while (p0 < p1)
do
{
EMIT_ONE_BYTE (*p0);
p0++;
}
while (p0 < p1);
}
}
else