Commit message (Collapse) | Author | Age | Files | Lines | |
---|---|---|---|---|---|
* | Merge 0.11->trunk | Matthew Wild | 2020-10-16 | 2 | -1/+94 |
|\ | |||||
| * | util.debug: Fix locals being reported under wrong stack frame in some cases ↵ | Matthew Wild | 2020-10-16 | 2 | -1/+94 |
| | | | | | | | | (+tests!!) | ||||
* | | Merge 0.11->trunk | Kim Alvefur | 2020-10-15 | 1 | -0/+4 |
|\| | |||||
| * | Back out changeset 2c1583bb0e0f | Kim Alvefur | 2020-10-15 | 1 | -0/+4 |
| | | | | | | | | Same reason as 712b2e6a09d9 | ||||
* | | util.sasl.scram: Use util.strbitop for XOR step | Kim Alvefur | 2019-09-07 | 1 | -29/+1 |
| | | |||||
* | | Merge 0.11->trunk | Kim Alvefur | 2020-10-15 | 1 | -17/+6 |
|\| | |||||
| * | Back out 6dde2c9fa272: Doesn't work on Lua 5.1 | Kim Alvefur | 2020-10-15 | 1 | -13/+6 |
| | | |||||
| * | util.strbitop: Remove redundant init function | Kim Alvefur | 2020-10-15 | 1 | -4/+0 |
| | | | | | | | | | | When you have 3 almost identical functions, you tend to edit one and then copypaste. Forgot to remove this line from the other two. | ||||
* | | Merge 0.11->trunk | Kim Alvefur | 2020-10-15 | 2 | -15/+63 |
|\| | |||||
| * | util.strbitop: Create buffer in the correct size (optimization) | Kim Alvefur | 2020-10-15 | 1 | -6/+13 |
| | | | | | | | | | | This avoids dynamically growing the buffer as Lua does when luaL_addchar is used, thus saving on realloc calls. | ||||
| * | util.strbitop: Add tests covering basics | Kim Alvefur | 2020-10-15 | 1 | -0/+41 |
| | | | | | | | | Also as docs | ||||
| * | util.strbitop: Reformat code | Kim Alvefur | 2020-10-15 | 1 | -9/+9 |
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | astyle \ --indent=tab \ --attach-classes \ --indent-switches \ --break-blocks \ --pad-oper \ --unpad-paren \ --add-braces \ --align-pointer=name \ --lineend=linux \ *.c | ||||
* | | Merge 0.11->trunk | Matthew Wild | 2020-10-15 | 5 | -29/+114 |
|\| | |||||
| * | net.websocket.frames: Add test for empty frame with MASK and key set | Matthew Wild | 2020-10-15 | 1 | -0/+10 |
| | | |||||
| * | net.websocket.frames: Use C string XOR implementation | Kim Alvefur | 2020-10-14 | 2 | -24/+8 |
| | | |||||
| * | util.strbitop: Library for bitwise operations on strings | Kim Alvefur | 2019-09-07 | 3 | -2/+93 |
| | | |||||
| * | net.websocket.frames: Add small test covering xor-masking | Kim Alvefur | 2020-10-14 | 1 | -0/+13 |
| | | | | | | | | This is basically a recording of current behavior, to detect changes. | ||||
* | | util.error: Pass through existing error objects passed to new() | Matthew Wild | 2020-10-15 | 1 | -0/+1 |
| | | |||||
* | | Merge 0.11->trunk | Matthew Wild | 2020-10-13 | 1 | -1/+4 |
|\| | |||||
| * | net.http.server: Don't send Content-Length on 1xx/204 responses, per RFC ↵ | Matthew Wild | 2020-10-13 | 1 | -1/+4 |
| | | | | | | | | (fixes #1596) | ||||
* | | Merge 0.11->trunk | Kim Alvefur | 2020-10-12 | 3 | -3/+5 |
|\| | |||||
| * | net.websocket.frames: Read buffer length correctly in Lua 5.1 (fix #1598) | Kim Alvefur | 2020-10-12 | 1 | -3/+3 |
| | | | | | | | | | | | | | | COMPAT: The __len metamethod does not work with tables in Lua 5.1. Both strings and util.dbuffer now expose their length as a :len() method. | ||||
| * | util.dbuffer: Expose length as :len() method, like strings | Kim Alvefur | 2020-10-12 | 2 | -0/+2 |
| | | | | | | | | Ref #1598 | ||||
* | | mod_http_errors: Remove 'extra' element when empty | Kim Alvefur | 2020-10-12 | 1 | -1/+1 |
| | | |||||
* | | mod_http_errors: Dark theme! | Kim Alvefur | 2020-10-12 | 1 | -0/+7 |
| | | |||||
* | | mod_http_errors: Use a class on extra data section | Kim Alvefur | 2020-10-12 | 1 | -2/+2 |
| | | | | | | | | This CSS selector makes it awkward to add more items. | ||||
* | | util.startup: Handle missing nparams field from debug info (not present in 5.1) | Matthew Wild | 2020-10-11 | 1 | -2/+3 |
| | | |||||
* | | core.modulemanager: Fix error if installer path missing | Kim Alvefur | 2020-10-11 | 1 | -1/+1 |
| | | | | | | | | | | Happens if run outside prosody. Noticed because because the storage tests fail. | ||||
* | | util.startup: Include arguments in function string representation | Kim Alvefur | 2020-10-09 | 1 | -2/+8 |
| | | | | | | | | | | | | | | Improves usability of the console when digging around the internals. No specific rationale for the function<file:line>(args) format, it looked best of the variants I tried. | ||||
* | | util.startup: Retrieve less data for function string representation | Kim Alvefur | 2020-10-09 | 1 | -1/+1 |
| | | | | | | | | debug.getinfo(f) collects more info than what is needed here. | ||||
* | | core.moduleapi: Return resource path from module:get_directory() (API BC) | Kim Alvefur | 2020-10-09 | 1 | -2/+2 |
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | :get_directory has so far returned the base directory of the current module source code. This has worked well so far to load resources which tend to be included in the same directory, but with the plugin installer using LuaRocks, extra resources (e.g. templates and other assets) these are saved in a completely different directory. In be73df6765b9 core.modulemanager gained some code for finding that directory and saving it in module.resource_path but now the question is how this should be reflected in the API. A survey of community modules suggest the vast majority use the :get_directory method for locating templates and other assets, rather than the code (which would use module:require instead). Therefore this commit changes :get_directory to return the resource_path when available. This should work for most modules. | ||||
* | | core.modulemanager: Add compat for LuaRocks 2.x | Kim Alvefur | 2020-10-07 | 1 | -0/+7 |
| | | |||||
* | | core.moduleapi: Use resource path for :load_resource() | Kim Alvefur | 2020-10-07 | 1 | -1/+1 |
| | | |||||
* | | core.modulemanager: Locate resources of LuaRocks-installed modules | Kim Alvefur | 2020-10-07 | 1 | -0/+31 |
| | | | | | | | | | | | | | | Extra non-code files included with a `copy_directories` directive in a LuaRocks manifest will be copied into a per-module and per-version directory under /lib/luarocks/ and all this is there to dig that out so it can be used in e.g. moduleapi :load_resource(). | ||||
* | | util.startup: Save the path used by the installer to prosody.paths | Kim Alvefur | 2020-10-07 | 1 | -0/+1 |
| | | | | | | | | | | | | Makes it easier for other parts of the code to use this for things, such as determining whether a certain module is from this path or from elsewhere. | ||||
* | | Merge 0.11->trunk | Kim Alvefur | 2020-10-07 | 1 | -2/+2 |
|\| | |||||
| * | MUC: Preserve disco 'node' attribute (or lack thereof) in response (fix ↵ | Kim Alvefur | 2020-10-07 | 1 | -2/+2 |
| | | | | | | | | #1595) (thanks lessthan3) | ||||
* | | Merge 0.11->trunk | Kim Alvefur | 2020-10-05 | 1 | -2/+2 |
|\| | |||||
| * | util.dependencies: Check for bitop library same way as net.websocket.frames ↵ | Kim Alvefur | 2020-10-05 | 1 | -1/+1 |
| | | | | | | | | (fixes #1594) | ||||
| * | MUC: Correct advertising of subject write access (really fixes #1155) | Kim Alvefur | 2020-10-04 | 1 | -2/+2 |
| | | | | | | | | | | | | | | | | | | | | Thanks pep. and lovetox XEP-0045 §6.4: > any field defined for the muc\#roomconfig FORM_TYPE can be included in > the extended service discovery fields Probably happened because the same mistake is in #1155 | ||||
* | | util.startup: Fix startup failure if CFG_DATADIR is unset | Kim Alvefur | 2020-10-05 | 1 | -1/+1 |
| | | | | | | | | As is normal when running from source | ||||
* | | util.startup: Re-enable installer path setup | Kim Alvefur | 2020-10-05 | 1 | -2/+2 |
| | | |||||
* | | util.startup: Put 'installer_plugin_path' under data directory by default | Kim Alvefur | 2020-10-05 | 1 | -1/+1 |
| | | | | | | | | | | Fixes issue where it ends up creating this in $PWD, which might be ~prosody, ~you or /, depending on how it's invoked. | ||||
* | | util.prosodyctl: Simplify luarocks invocation | Kim Alvefur | 2020-10-05 | 1 | -7/+3 |
| | | |||||
* | | util.prosodyctl: Get Luarocks server from config | Kim Alvefur | 2020-10-05 | 1 | -1/+2 |
| | | |||||
* | | util.prosodyctl: Move hardcoded luarocks server into prosodyctl | Kim Alvefur | 2020-10-05 | 2 | -3/+3 |
| | | | | | | | | To be replaced with config option in future commit | ||||
* | | util.prosodyctl: Flip argument order | Kim Alvefur | 2020-10-05 | 2 | -4/+4 |
| | | | | | | | | | | "verb subject" feels better than "subject verb", especially since the subject (module) is optional. | ||||
* | | util.prosodyctl: Construct luarocks command line with templates | Kim Alvefur | 2020-10-05 | 1 | -2/+7 |
| | | | | | | | | More flexible and safer wrt escaping | ||||
* | | util.pluginloader: Look for module libs in mod_plugin/lib.lua | Kim Alvefur | 2020-10-05 | 1 | -0/+3 |
| | | | | | | | | | | Luarocks can't be told to install something as foo.lib.lua AFAIK, so instead let's try mod_bar/foo.lua | ||||
* | | util.pluginloader: Look for top level mod_something.lua in luarocks-style tree | Kim Alvefur | 2020-10-05 | 1 | -0/+1 |
| | |