From 62401d5655c675fab550131d13455ffbf9b3d3e5 Mon Sep 17 00:00:00 2001 From: Hugues Delorme Date: Thu, 28 May 2015 16:20:27 +0200 Subject: [PATCH] gmio_core: fix bug in gmio_eat_word() --- src/gmio_core/internal/string_parse.c | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/src/gmio_core/internal/string_parse.c b/src/gmio_core/internal/string_parse.c index 7da58fe..fd45fbc 100644 --- a/src/gmio_core/internal/string_parse.c +++ b/src/gmio_core/internal/string_parse.c @@ -54,14 +54,9 @@ int gmio_eat_word( if (i < buffer_capacity) { buffer->ptr[i] = 0; /* End string with terminating null byte */ buffer->len = i; - if (stream_curr_char != NULL - || gmio_stream_at_end(it->stream) == GMIO_TRUE) - { - return 0; - } - return -3; + return 0; } - return -4; + return -1; } gmio_bool_t gmio_checked_next_chars(