Changeset 45c7e97 in serd


Ignore:
Timestamp:
Sep 23, 2017, 6:59:23 AM (8 weeks ago)
Author:
David Robillard <d@…>
Branches:
master, serd1
Children:
65f7c3f
Parents:
162de28
git-author:
David Robillard <d@…> (09/23/17 06:39:18)
git-committer:
David Robillard <d@…> (09/23/17 06:59:23)
Message:

Report errors when lax parsing

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/reader.c

    r162de28 r45c7e97  
    643643                                    eat_byte_safe(reader, c)))) {
    644644        return st;
    645     } else if (reader->strict && !is_PN_CHARS_BASE(code)) {
     645    } else if (!is_PN_CHARS_BASE(code)) {
    646646        r_err(reader, SERD_ERR_BAD_SYNTAX,
    647647              "invalid character U+%04X in name\n", code);
    648         return SERD_ERR_BAD_SYNTAX;
     648        if (reader->strict) {
     649            return SERD_ERR_BAD_SYNTAX;
     650        }
    649651    }
    650652    return st;
     
    671673                                    eat_byte_safe(reader, c)))) {
    672674        return st;
    673     } else if (reader->strict && !is_PN_CHARS(code)) {
     675    } else if (!is_PN_CHARS(code)) {
    674676        r_err(reader, (st = SERD_ERR_BAD_SYNTAX),
    675677              "invalid character U+%04X in name\n", code);
Note: See TracChangeset for help on using the changeset viewer.