From ecf6e517b5f65397507697c28c29981507a052ab Mon Sep 17 00:00:00 2001 From: John Mark Bell Date: Wed, 13 Aug 2008 11:09:37 +0000 Subject: Move the location of the utf8 buffer every time we're asked for a character in debug mode. This leaks memory lots, deliberately. svn path=/trunk/libparserutils/; revision=5081 --- include/parserutils/input/inputstream.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'include/parserutils/input') diff --git a/include/parserutils/input/inputstream.h b/include/parserutils/input/inputstream.h index db81eb0..26f3353 100644 --- a/include/parserutils/input/inputstream.h +++ b/include/parserutils/input/inputstream.h @@ -85,6 +85,8 @@ static inline uintptr_t parserutils_inputstream_peek( if (stream == NULL) return PARSERUTILS_INPUTSTREAM_OOD; + parserutils_buffer_randomise(stream->utf8); + #define IS_ASCII(x) (((x) & 0x80) == 0) if (stream->cursor + offset < stream->utf8->length) { -- cgit v1.2.3