** Read an integer numeral and raises an error if it is larger ** than the maximum size for integers. */
| 1413 | ** than the maximum size for integers. |
| 1414 | */ |
| 1415 | static int getnumlimit (Header *h, const char **fmt, int df) { |
| 1416 | int sz = getnum(fmt, df); |
| 1417 | if (l_unlikely(sz > MAXINTSIZE || sz <= 0)) |
| 1418 | return luaL_error(h->L, "integral size (%d) out of limits [1,%d]", |
| 1419 | sz, MAXINTSIZE); |
| 1420 | return sz; |
| 1421 | } |
| 1422 | |
| 1423 | |
| 1424 | /* |
no test coverage detected