1
0
Fork 0
mirror of git://git.psyc.eu/libpsyc synced 2024-08-15 03:19:02 +00:00

tests & fix for 0 length modifier value

This commit is contained in:
tg(x) 2011-05-04 17:59:51 +02:00
parent e7a4df6180
commit c4340bae9f
6 changed files with 25 additions and 2 deletions

View file

@ -109,6 +109,7 @@ typedef struct
psycBool contentLengthFound; ///< is there a length given for this packet?
size_t valueParsed; ///< number of bytes parsed from the value so far
size_t valueLength; ///< expected length of the value
psycBool valueLengthFound; ///< is there a length given for this modifier?
} psycParseState;
/**
@ -231,6 +232,12 @@ size_t psyc_getParseValueLength (psycParseState *state)
return state->valueLength;
}
static inline
psycBool psyc_isParseValueLengthFound (psycParseState *state)
{
return state->valueLengthFound;
}
static inline
size_t psyc_getParseCursor (psycParseState *state)
{