diff options
| author | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2023-11-24 16:08:55 -0300 |
|---|---|---|
| committer | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2023-11-24 16:08:55 -0300 |
| commit | 842a83f09caa2ebd4bc03e0076420148ac07c808 (patch) | |
| tree | 92eca69ee75b32156b14c1a9d0b5a31f16ef9118 /manual | |
| parent | 7923dbbf72da303ca1cca17efd24725668992f15 (diff) | |
| download | lua-842a83f09caa2ebd4bc03e0076420148ac07c808.tar.gz lua-842a83f09caa2ebd4bc03e0076420148ac07c808.tar.bz2 lua-842a83f09caa2ebd4bc03e0076420148ac07c808.zip | |
Panic functions should not raise errors
The standard panic function was using 'lua_tostring', which may raise
a memory-allocation error if error value is a number.
Diffstat (limited to 'manual')
| -rw-r--r-- | manual/manual.of | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/manual/manual.of b/manual/manual.of index ad120f5e..cef3e22a 100644 --- a/manual/manual.of +++ b/manual/manual.of | |||
| @@ -4486,6 +4486,10 @@ This string always has a zero (@Char{\0}) | |||
| 4486 | after its last character (as @N{in C}), | 4486 | after its last character (as @N{in C}), |
| 4487 | but can contain other zeros in its body. | 4487 | but can contain other zeros in its body. |
| 4488 | 4488 | ||
| 4489 | This function can raise memory errors only | ||
| 4490 | when converting a number to a string | ||
| 4491 | (as then it has to create a new string). | ||
| 4492 | |||
| 4489 | } | 4493 | } |
| 4490 | 4494 | ||
| 4491 | @APIEntry{lua_Number lua_tonumber (lua_State *L, int index);| | 4495 | @APIEntry{lua_Number lua_tonumber (lua_State *L, int index);| |
