Eric Covener
659cf30d6f
PR63971 expose apr_table_unset for headers/envvars
...
via nil assignment
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1870650 13f79535-47bb-0310-9956-ffa450edef68
2019-11-30 20:28:36 +00:00
Rainer Jung
3490bd62b6
Fix last compat issue with Lua 5.2 and 5.3.
...
Patch taken from PR58188 which picked it from
openSUSE.
Still needs testing.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1800817 13f79535-47bb-0310-9956-ffa450edef68
2017-07-04 20:48:43 +00:00
Christophe Jaillet
56d0c25725
Add missing APLOGNO.
...
Refactor some lines to keep APLOGNO on the same line as ap_log_error, when applicable.
Split lines longer than 80.
Improve alignment.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1612068 13f79535-47bb-0310-9956-ffa450edef68
2014-07-20 09:32:58 +00:00
Daniel Gruno
b6899453ab
Add a note on t->r checking, as per Rüdiger's email.
...
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1582881 13f79535-47bb-0310-9956-ffa450edef68
2014-03-28 20:43:15 +00:00
Daniel Gruno
29e243b1fb
mod_lua: Since c->notes is the only place where r will be NULL, we don't need to check a second time, since we'll never meddle with tables named 'notes'
...
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1582877 13f79535-47bb-0310-9956-ffa450edef68
2014-03-28 20:33:08 +00:00
Daniel Gruno
d38e1b6e83
mod_lua: Redesign the table construction/access mechanism, so we pass on a struct with the request_rec, the table pointer and the table name instead of just the table pointer. This allows us to use the request_rec for logging/editing purposes, as well as inform the user which exact table in the request_rec was modified.
...
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1582858 13f79535-47bb-0310-9956-ffa450edef68
2014-03-28 18:38:41 +00:00
Daniel Gruno
8ae663bc78
mod_lua: Prevent HTTP Response Splitting by not allowing tables in the request_rec to be set with values containing newlines. This is a semi-ugly hack, but it will have to do until we find another way of setting these values.
...
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1582262 13f79535-47bb-0310-9956-ffa450edef68
2014-03-27 11:20:03 +00:00
Guenter Knauf
4e7640be1d
Remove unneeded exports from mod_lua.
...
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1487956 13f79535-47bb-0310-9956-ffa450edef68
2013-05-30 18:28:24 +00:00
Guenter Knauf
e71d636f79
Removed obsolete define (already exists in mod_lua.h).
...
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1485292 13f79535-47bb-0310-9956-ffa450edef68
2013-05-22 17:19:47 +00:00
Daniel Gruno
49fcd96e73
Using the traditional way of declaring Lua functions does not seem to work with NetWare (and possibly Windows too?)
...
Thus, at least until we find a smarter way, we have to move the r:* functions into lua_request.c and connect them from there.
The only functional change is that the transferred functions are now called through the request object instead of the apache2 package.
The distinction between what merited it to be in either structure seems very vague, so for now, we'll keep the HTTP return codes in the apache2 table, and the request/server functions in the request object.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1433967 13f79535-47bb-0310-9956-ffa450edef68
2013-01-16 14:52:52 +00:00
Stefan Fritsch
7deeb8782a
fix typo: || not |
...
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1429169 13f79535-47bb-0310-9956-ffa450edef68
2013-01-04 23:48:15 +00:00
Daniel Gruno
3d8bdb7d7c
Style tweaks, remove add_version_component and fix up some sloppy code. Many thanks to sfritsch for the pointers!
...
And a merry christmas everyone :)
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1425450 13f79535-47bb-0310-9956-ffa450edef68
2012-12-23 10:28:16 +00:00
Daniel Gruno
1050577245
Style tweaks, no functional change.
...
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1425243 13f79535-47bb-0310-9956-ffa450edef68
2012-12-22 05:25:50 +00:00
Stefan Fritsch
a70974b4d9
use ap_bin2hex() to simplify md5/sha1 code
...
also fixes some 'array subscript is above array bounds' warnings
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1422552 13f79535-47bb-0310-9956-ffa450edef68
2012-12-16 11:51:56 +00:00
Stefan Fritsch
4cd818b34b
remove unused variable
...
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1422548 13f79535-47bb-0310-9956-ffa450edef68
2012-12-16 11:48:19 +00:00
Daniel Gruno
999476f7f7
mod_lua: Fix unitialized variable in lua_ap_send_interim_response.
...
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1422531 13f79535-47bb-0310-9956-ffa450edef68
2012-12-16 11:30:54 +00:00
Daniel Gruno
5a3e2e44dc
mod_lua: If a regex fails, return false plus an error message as second return value. Also fix some functions who weren't always returning a value.
...
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1422373 13f79535-47bb-0310-9956-ffa450edef68
2012-12-15 22:03:47 +00:00
Daniel Gruno
ff81e58f05
mod_lua: Fix Windows compatibility issues and remove an unused variable. Thanks, Gregg!
...
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1422072 13f79535-47bb-0310-9956-ffa450edef68
2012-12-14 20:44:41 +00:00
Daniel Gruno
b849415518
mod_lua: Oops, there was a stray 'int i' in the middle of lua_ap_regex.
...
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1421784 13f79535-47bb-0310-9956-ffa450edef68
2012-12-14 10:25:31 +00:00
Daniel Gruno
df178d1e41
mod_lua: Fix signedness/other small bugs as per cjaillet/fuankg's emails - thanks guys :)
...
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1421780 13f79535-47bb-0310-9956-ffa450edef68
2012-12-14 10:15:37 +00:00
Daniel Gruno
3b6cdb0f92
mod_lua: Add a lot of core httpd/apr functionality to mod_lua
...
(such as regex matching, expr evaluation, changing/fetching server configuration/info - see docs for a complete list).
This also includes a bunch of automatically scraped functions, which may or may not be super useful.
Comments appreciated as always, especially on the more hacky bits.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1420377 13f79535-47bb-0310-9956-ffa450edef68
2012-12-11 20:08:24 +00:00
Rainer Jung
d0257e2db8
luaL_reg was already deprecated in Lua 5.1.4.
...
It is gone in Lua 5.2.0 and was replaced by luaL_Reg
which already existed in 5.1.4. So use that one..
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1239029 13f79535-47bb-0310-9956-ffa450edef68
2012-02-01 09:50:14 +00:00
Stefan Fritsch
1951a037bf
More cleanup: Expand tabs and some more indentation fixes
...
No functional change
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1174929 13f79535-47bb-0310-9956-ffa450edef68
2011-09-23 18:08:42 +00:00
William A. Rowe Jr
a38b9f9117
Not static; trusting this targetted for export?
...
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@808726 13f79535-47bb-0310-9956-ffa450edef68
2009-08-28 01:39:50 +00:00
Brian McCallister
c194519800
change use of luaL_openlib to luaL_register via path from Arfrever Frehtes Taifersar Arahesis
...
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@784644 13f79535-47bb-0310-9956-ffa450edef68
2009-06-15 03:10:06 +00:00
Brian McCallister
3268b2daf4
change use of luaL_openlib to luaL_register via path from Arfrever Frehtes Taifersar Arahesis
...
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@784643 13f79535-47bb-0310-9956-ffa450edef68
2009-06-15 03:10:03 +00:00
William A. Rowe Jr
aa4b1cff0b
fix symbol space and exports
...
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@758428 13f79535-47bb-0310-9956-ffa450edef68
2009-03-25 20:09:08 +00:00
Brian McCallister
0f4cf6e591
changes headers_in and headers_out handling in mod_lua to map apr_table_t instances as boxed pointers
...
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@737293 13f79535-47bb-0310-9956-ffa450edef68
2009-01-24 03:10:40 +00:00
Paul Querna
ce336c773a
Attempt to make mod_lua compile under a strict c89 compiler by moving all variable declarations to be before code.
...
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@728539 13f79535-47bb-0310-9956-ffa450edef68
2008-12-21 22:38:07 +00:00
Paul Querna
729bcf2b58
Reformat mod_lua according to the HTTP Server Project C Style Guide:
...
<http://httpd.apache.org/dev/styleguide.html >
No functional changes.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@728516 13f79535-47bb-0310-9956-ffa450edef68
2008-12-21 21:41:52 +00:00
Paul Querna
41fa7d796a
Include standard ASF license block.
...
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@728512 13f79535-47bb-0310-9956-ffa450edef68
2008-12-21 21:32:04 +00:00
Paul Querna
3948867f51
Rename all files in mod_lua to have a lua_ prefix, as things like 'config.h' are way to generic and will often conflict with other include files.
...
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@728508 13f79535-47bb-0310-9956-ffa450edef68
2008-12-21 21:27:01 +00:00