]> granicus.if.org Git - libexpat/commitdiff
tests: Fix test_byte_info_at_cdata for undefined XML_CONTEXT_BYTES
authorSebastian Pipping <sebastian@pipping.org>
Tue, 2 May 2017 22:37:02 +0000 (00:37 +0200)
committerSebastian Pipping <sebastian@pipping.org>
Tue, 2 May 2017 22:38:57 +0000 (00:38 +0200)
expat/tests/runtests.c

index 8e74c34e72c176bcd716bd7ee9f82bed81fb59f9..4adedf91c9c474dc5c0cdf7a18e4e4383e39fd82 100644 (file)
@@ -2250,6 +2250,7 @@ byte_character_handler(void *userData,
                        const XML_Char *s,
                        int len)
 {
+#ifdef XML_CONTEXT_BYTES
     int offset, size;
     const char *buffer;
     intptr_t buflen = (intptr_t)userData;
@@ -2265,6 +2266,7 @@ byte_character_handler(void *userData,
         fail("Buffer length incorrect");
     if (s != buffer + offset)
         fail("Buffer position incorrect");
+#endif
 }
 
 START_TEST(test_byte_info_at_cdata)