From f5b2e6b149d13213b7f72df0e2b02d3f86b74ee1 Mon Sep 17 00:00:00 2001 From: why Date: Mon, 19 May 2003 16:37:20 +0000 Subject: * lib/syck.c, lib/syck.h, lib/token.c, lib/gram.c: count line numbers only if line pointer has increased. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@3829 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- ext/syck/syck.c | 3 +++ 1 file changed, 3 insertions(+) (limited to 'ext/syck/syck.c') diff --git a/ext/syck/syck.c b/ext/syck/syck.c index 36e95fd80a..89aa804e44 100644 --- a/ext/syck/syck.c +++ b/ext/syck/syck.c @@ -136,6 +136,7 @@ syck_parser_reset_cursor( SyckParser *p ) p->cursor = NULL; p->lineptr = NULL; + p->linectptr = NULL; p->token = NULL; p->toktmp = NULL; p->marker = NULL; @@ -397,6 +398,7 @@ syck_move_tokens( SyckParser *p ) p->toktmp -= count; p->limit -= count; p->lineptr -= count; + p->linectptr -= count; } return skip; } @@ -408,6 +410,7 @@ syck_check_limit( SyckParser *p, long len ) { p->cursor = p->buffer; p->lineptr = p->buffer; + p->linectptr = p->buffer; p->marker = p->buffer; } p->limit = p->buffer + len; -- cgit v1.2.3