Fix bug in case of empty array and the type doesn't flush the stream.
This commit is contained in:
1 parent
b3239e8391
commit
320977e1fa
1 file changed
+2
-2
@@ -600,9 +600,9 @@
|
||||
M_GET_INIT oplist (item); \
|
||||
do { \
|
||||
bool b = M_GET_IN_STR oplist (item, file); \
|
||||
if (!b) { M_GET_CLEAR oplist (item); return false; } \
|
||||
M_C3(array_, name, _push_back)(array, item); \
|
||||
c = fgetc(file); \
|
||||
if (!b) { /* How to push back char in stream ? */ break; } \
|
||||
M_C3(array_, name, _push_back)(array, item); \
|
||||
} while (c == M_GET_SEPARATOR oplist && !feof(file) && !ferror(file)); \
|
||||
M_GET_CLEAR oplist (item); \
|
||||
return c == ']'; \
|
||||
|
||||
Reference in new issue
Block a user