** Get a space of size 'sz' in the buffer. If buffer has not enough ** space, empty it. 'sz' must fit in an empty buffer. */
| 436 | ** space, empty it. 'sz' must fit in an empty buffer. |
| 437 | */ |
| 438 | static char *getbuff (BuffFS *buff, int sz) { |
| 439 | lua_assert(buff->blen <= BUFVFS); lua_assert(sz <= BUFVFS); |
| 440 | if (sz > BUFVFS - buff->blen) /* not enough space? */ |
| 441 | clearbuff(buff); |
| 442 | return buff->space + buff->blen; |
| 443 | } |
| 444 | |
| 445 | |
| 446 | #define addsize(b,sz) ((b)->blen += (sz)) |
no test coverage detected