Usually, the block number can grow to 20 bits which is not
guaranteed to fit in a single unsigned int. To avoid compilers
(especially msp430-gcc) complaining about the width of the used
bit field, the type for num has been changed to unsigned int
hence restricting the number of acceptable blocks to 65536 on
those platforms. (No bounds check is done yet.)
m and szx now share a uint8_t.
The macro did not respect zero-length option values hence a pointer
to the option byte itself was returned. This macro now returns NULL
for zero-length option values. Macros and functions that use this
macro have been updated accordingly. COAP_OPT_BLOCK_NUM has been
replaced by the function coap_opt_block_num().
The function wellknown_response() now honors a Block2 option when present
in the request or adds a new Block2 option to the response when the resource
description does not fit.
Bug: get_wkc_len() currently returns a hard-coded value instead of calculating
the size of the resource description (which requires changes in resource.c).