Changed FRAMER to return negative values for error to allow 0 size headers.

This commit is contained in:
Joakim Eriksson 2011-12-31 18:00:21 -08:00 committed by Niclas Finne
parent d89a4ef4fd
commit 65163a9b57
9 changed files with 239 additions and 23 deletions

View file

@ -69,7 +69,7 @@ create(void)
return sizeof(struct nullmac_hdr);
}
PRINTF("PNULLMAC-UT: too large header: %u\n", len);
return 0;
return FRAMER_FAILED;
}
/*---------------------------------------------------------------------------*/
static int
@ -88,7 +88,7 @@ parse(void)
return sizeof(struct nullmac_hdr);
}
return 0;
return FRAMER_FAILED;
}
/*---------------------------------------------------------------------------*/
const struct framer framer_nullmac = {