summaryrefslogtreecommitdiff
path: root/src/tokeniser/tokeniser.c
Commit message (Collapse)AuthorAgeFilesLines
* tokeniser: Constify token through hubbub_tokeniser_emit_token().Michael Drake2021-05-241-2/+2
|
* Consume insert_buf when resuming a parseDaniel Silverstone2019-05-061-0/+18
| | | | Signed-off-by: Daniel Silverstone <dsilvers@digital-scurf.org>
* Remove client allocation function and update for new lpu API.Michael Drake2013-12-141-24/+12
|
* Fix uninitialised pause variableVincent Sanders2012-07-131-0/+2
|
* Add ability to pause tokenisationVincent Sanders2012-07-101-1/+23
|
* Insert data at correct point in input stream.John-Mark Bell2012-07-051-0/+45
|
* Fix build with GCC 4.6John Mark Bell2011-07-261-6/+11
| | | | svn path=/trunk/hubbub/; revision=12628
* Remove init/final and embed entity trie at build time. r=vinceDaniel Silverstone2010-12-041-2/+2
| | | | svn path=/trunk/hubbub/; revision=10976
* Make assignment of doctype component pointers clearer. Also removes a ↵John Mark Bell2009-05-271-9/+6
| | | | | | redundant pointer increment. svn path=/trunk/hubbub/; revision=7581
* Remove redundant code.John Mark Bell2009-05-271-13/+0
| | | | svn path=/trunk/hubbub/; revision=7580
* Initialise variables to stop GCC 4.4 complaining (credit: Jeroen Habraken)John Mark Bell2009-05-051-4/+4
| | | | svn path=/trunk/hubbub/; revision=7398
* Improve error handling in the tokeniserJohn Mark Bell2009-04-061-62/+154
| | | | svn path=/trunk/hubbub/; revision=7052
* hubbub_alloc -> hubbub_allocator_fnJohn Mark Bell2009-04-041-2/+3
| | | | svn path=/trunk/hubbub/; revision=7043
* Sync tokeniser tests with html5lib.John Mark Bell2009-03-101-12/+19
| | | | | | | | Sync tokeniser implementation with the spec. Fix handling of \0 in the tag open state. The unicodeCharacters test is disabled, as json-c doesn't like it. svn path=/trunk/hubbub/; revision=6755
* Make doxygen produce API documentation. I guess it helps if you enable the ↵John Mark Bell2009-01-081-1/+1
| | | | | | | | right options. Fix a couple more doxygen warnings. svn path=/trunk/hubbub/; revision=5996
* Use doxygen to create API documentation.John Mark Bell2009-01-081-12/+13
| | | | | | Add a bunch of extra commentary to stop doxygen warning. svn path=/trunk/hubbub/; revision=5994
* Fix potential read beyond available input data when processing \r in some ↵John Mark Bell2009-01-061-5/+5
| | | | | | | | | | states. What happened was that, given \rabc, we would advance past the \r, then read at current_offset + len (len == 1). I.E. read 'b' instead of 'a'. If the data in the inputstream's internal buffer happened to end immediately after the \r, then we'd read past the end of the buffer thanks to a bug in lpu_inputstream_peek which was fixed in r5965. In any case, we'd still be looking at the wrong character when looking for CRLF pairs. All regression tests now pass again. svn path=/trunk/hubbub/; revision=5967
* Port to changed lpu API.John Mark Bell2009-01-061-455/+635
| | | | | | | Drop HUBBUB_OOD and just use HUBBUB_NEEDDATA, instead. Currently aborts in bogus comment handling if it encounters a \r at the end of the inputstream's utf-8 buffer. svn path=/trunk/hubbub/; revision=5966
* Fix build breakageJohn Mark Bell2008-11-301-1/+3
| | | | svn path=/trunk/hubbub/; revision=5851
* lotsa C89, please check.François Revel2008-11-301-48/+91
| | | | svn path=/trunk/hubbub/; revision=5846
* Return errors from tokeniser constructor/destructorJohn Mark Bell2008-11-091-13/+22
| | | | svn path=/trunk/hubbub/; revision=5664
* Port hubbub to new lpu APIJohn Mark Bell2008-11-081-2/+3
| | | | svn path=/trunk/hubbub/; revision=5656
* Squash memory leakJohn Mark Bell2008-09-081-0/+2
| | | | svn path=/trunk/hubbub/; revision=5285
* Fixes for handling of CR followed immediately by multibyte sequences.John Mark Bell2008-09-061-59/+94
| | | | | | | Pedantic whitespace changes. More paranoia surrounding entity handling. svn path=/trunk/hubbub/; revision=5266
* Fix segfault caused by trampling the length of the current character when ↵John Mark Bell2008-08-181-2/+8
| | | | | | | | testing whether the 4 most recently read characters in the data state are <!--. Add a couple of assertions for paranoia. svn path=/trunk/hubbub/; revision=5146
* Do what r5107 for system ID for public IDs.Andrew Sidwell2008-08-131-14/+4
| | | | svn path=/trunk/hubbub/; revision=5108
* Another COLLECT() -> COLLECT_MS() fix.Andrew Sidwell2008-08-131-14/+4
| | | | svn path=/trunk/hubbub/; revision=5107
* Add page which crashed, and fix the bug that caused it to do so.Andrew Sidwell2008-08-131-4/+2
| | | | svn path=/trunk/hubbub/; revision=5106
* Remove the CHAR() macro, which lets make test run again.Andrew Sidwell2008-08-131-80/+74
| | | | svn path=/trunk/hubbub/; revision=5104
* Optimise COLLECT_MS() macro.Andrew Sidwell2008-08-131-5/+3
| | | | svn path=/trunk/hubbub/; revision=5099
* Fix segfault in elimination of duplicate attributes.John Mark Bell2008-08-131-7/+8
| | | | svn path=/trunk/hubbub/; revision=5098
* Optimise comment states slightly, taking advantage of the fact that buffers ↵Andrew Sidwell2008-08-131-20/+1
| | | | | | store their own length and when emitting the comment, the buffer contains the whole comment and nothing else. svn path=/trunk/hubbub/; revision=5095
* Fix tokeniser so make test passes, with possible perf hit.Andrew Sidwell2008-08-131-18/+43
| | | | svn path=/trunk/hubbub/; revision=5093
* Use COLLECT_MS() macro rather than COLLECT() in attribute values.Andrew Sidwell2008-08-131-4/+4
| | | | svn path=/trunk/hubbub/; revision=5086
* Sanity checking for string dataJohn Mark Bell2008-08-131-0/+39
| | | | svn path=/trunk/hubbub/; revision=5080
* Remember to clear the self-closing flag when emitting a tag token.Andrew Sidwell2008-08-111-0/+3
| | | | svn path=/trunk/hubbub/; revision=5030
* - Remove an unused function from utils/string.cAndrew Sidwell2008-08-111-46/+1
| | | | | | | - Remove the no-op FINISH() macro from the tokeniser - Fix a typo in the charset detector svn path=/trunk/hubbub/; revision=5007
* Move one step closer to getting encoding changes working.Andrew Sidwell2008-08-111-1/+1
| | | | svn path=/trunk/hubbub/; revision=5000
* Propagate more return codes up the chain from the token emitter.Andrew Sidwell2008-08-091-55/+38
| | | | svn path=/trunk/hubbub/; revision=4980
* Propagate the use of hubbub_error up into at least a bit of the treebuilder.Andrew Sidwell2008-08-091-2/+4
| | | | svn path=/trunk/hubbub/; revision=4979
* Move tokeniser.c across to using hubbub_error for return codes, not bools, ↵Andrew Sidwell2008-08-091-227/+236
| | | | | | so that "encoding change" requests can be sent back down the chain from the treebuilder at some point. svn path=/trunk/hubbub/; revision=4978
* Really fix handling of entities in attributesJohn Mark Bell2008-08-041-1/+1
| | | | svn path=/trunk/hubbub/; revision=4894
* Fix previous commit.Andrew Sidwell2008-08-041-6/+14
| | | | svn path=/trunk/hubbub/; revision=4893
* Fix bug in hubbub & html5lib tests relating to parsing entities ending ↵Andrew Sidwell2008-08-041-1/+1
| | | | | | without semicolons in attribute values. svn path=/trunk/hubbub/; revision=4892
* Micro-optimisationAndrew Sidwell2008-08-041-2/+1
| | | | svn path=/trunk/hubbub/; revision=4890
* Rearrange emitting functions so they're all clumped together at the bottom ↵Andrew Sidwell2008-08-041-162/+172
| | | | | | of the file. svn path=/trunk/hubbub/; revision=4889
* Refactor tokeniser token-emitting bits to remove unnecessary conditionals.Andrew Sidwell2008-08-041-63/+62
| | | | svn path=/trunk/hubbub/; revision=4888
* Change tokeniser->context.chars from a hubbub_string whose ptr part is never ↵Andrew Sidwell2008-08-031-158/+155
| | | | | | used to simply tokeniser->context.pending. svn path=/trunk/hubbub/; revision=4882
* Remove some excessive indentation.Andrew Sidwell2008-08-031-27/+23
| | | | svn path=/trunk/hubbub/; revision=4881
* Remove the now-unnecessary COLLECT_*NOBUF() macros, replace them with the ↵Andrew Sidwell2008-08-031-79/+68
| | | | | | single statements they expanded to. svn path=/trunk/hubbub/; revision=4880