support SPC separator in timestamp

This commit is contained in:
CK Tan 2019-03-06 11:44:14 -08:00
parent c4325a38fb
commit bd76f1276e

3
toml.c
View file

@ -1701,7 +1701,8 @@ int toml_rtots(const char* src_, toml_timestamp_t* ret)
*ret->year = val; *ret->year = val;
if (*p) { if (*p) {
if (*p != 'T') return -1; // parse the T or space separator
if (*p != 'T' && *p != ' ') return -1;
p++; p++;
} }
} }