diff options
author | Hisham Muhammad <hisham@gobolinux.org> | 2022-02-08 16:26:03 -0300 |
---|---|---|
committer | Hisham Muhammad <hisham@gobolinux.org> | 2022-02-08 16:26:03 -0300 |
commit | 99b1ba350d3c933322db541f86ee7a5f70995e30 (patch) | |
tree | 2926e1a71ee7522215f7e876dd8495035fc8b31e /src | |
parent | f226ebefb536a8fea5e93863cff0afcdad005ce9 (diff) | |
download | luarocks-99b1ba350d3c933322db541f86ee7a5f70995e30.tar.gz luarocks-99b1ba350d3c933322db541f86ee7a5f70995e30.tar.bz2 luarocks-99b1ba350d3c933322db541f86ee7a5f70995e30.zip |
Fix crash when --lua-version is malformed
Diffstat (limited to 'src')
-rw-r--r-- | src/luarocks/cmd.lua | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/luarocks/cmd.lua b/src/luarocks/cmd.lua index 233bb1bd..962d9256 100644 --- a/src/luarocks/cmd.lua +++ b/src/luarocks/cmd.lua | |||
@@ -463,6 +463,7 @@ Enabling completion for Fish: | |||
463 | :argname("<prefix>") | 463 | :argname("<prefix>") |
464 | parser:option("--lua-version", "Which Lua version to use.") | 464 | parser:option("--lua-version", "Which Lua version to use.") |
465 | :argname("<ver>") | 465 | :argname("<ver>") |
466 | :convert(function(s) return (s:match("^%d+%.%d+$")) end) | ||
466 | parser:option("--tree", "Which tree to operate on.") | 467 | parser:option("--tree", "Which tree to operate on.") |
467 | :hidden_name("--to") | 468 | :hidden_name("--to") |
468 | parser:flag("--local", "Use the tree in the user's home directory.\n".. | 469 | parser:flag("--local", "Use the tree in the user's home directory.\n".. |