diff options
author | Robin Watts <robin.watts@artifex.com> | 2010-05-26 14:05:59 +0200 |
---|---|---|
committer | Robin Watts <robin.watts@artifex.com> | 2010-05-26 14:05:59 +0200 |
commit | 67a0351468df8c09f334f0cd1bff49712578e7c6 (patch) | |
tree | c6a54d20c13ee93700ad80ca350ab2127bba3d05 /fitz/stm_read.c | |
parent | cd39bd3a550165c5464f325956c30458b1ac9000 (diff) | |
download | mupdf-67a0351468df8c09f334f0cd1bff49712578e7c6.tar.xz |
Optimize lexer by using unreadbyte and switches rather than chained ifs.
Diffstat (limited to 'fitz/stm_read.c')
-rw-r--r-- | fitz/stm_read.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/fitz/stm_read.c b/fitz/stm_read.c index 9938b6e6..b01e300d 100644 --- a/fitz/stm_read.c +++ b/fitz/stm_read.c @@ -275,3 +275,8 @@ fz_peekbytex(fz_stream *stm) return buf->rp < buf->wp ? *buf->rp : EOF ; } +void fz_unreadbytex(fz_stream *stm) +{ + fz_buffer *buf = stm->buffer; + buf->rp--; +} |