summaryrefslogtreecommitdiff
path: root/ext/syck/syck.c
diff options
context:
space:
mode:
Diffstat (limited to 'ext/syck/syck.c')
-rw-r--r--ext/syck/syck.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/ext/syck/syck.c b/ext/syck/syck.c
index 20b124ab286..daf531632f7 100644
--- a/ext/syck/syck.c
+++ b/ext/syck/syck.c
@@ -412,7 +412,8 @@ syck_move_tokens( SyckParser *p )
skip = p->limit - p->token;
if ( ( count = p->token - p->buffer ) )
{
- S_MEMMOVE( p->buffer, p->token, char, skip );
+ if (skip > 0)
+ S_MEMMOVE( p->buffer, p->token, char, skip );
p->token = p->buffer;
p->marker -= count;
p->cursor -= count;