** Get a space of size 'sz' in the buffer. If buffer has not enough ** space, empty it. 'sz' must fit in an empty buffer. */
| 416 | ** space, empty it. 'sz' must fit in an empty buffer. |
| 417 | */ |
| 418 | static char *getbuff (BuffFS *buff, int sz) { |
| 419 | lua_assert(buff->blen <= BUFVFS); lua_assert(sz <= BUFVFS); |
| 420 | if (sz > BUFVFS - buff->blen) /* not enough space? */ |
| 421 | clearbuff(buff); |
| 422 | return buff->space + buff->blen; |
| 423 | } |
| 424 | |
| 425 | |
| 426 | #define addsize(b,sz) ((b)->blen += (sz)) |
no test coverage detected