Changeset

5230:6f5640375358

mod_http: Fix path length pattern
author Kim Alvefur <zash@zash.se>
date Sun, 09 Dec 2012 12:20:55 +0100
parents 5229:5566236f363f
children 5231:4f9135e6c2f9 5232:c9bb5879e193
files plugins/mod_http.lua
diffstat 1 files changed, 1 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/plugins/mod_http.lua	Sun Dec 09 12:19:08 2012 +0100
+++ b/plugins/mod_http.lua	Sun Dec 09 12:20:55 2012 +0100
@@ -88,7 +88,7 @@
 					local data = handler;
 					handler = function () return data; end
 				elseif event_name:sub(-2, -1) == "/*" then
-					local base_path_len = #event_name:match("(/.+/)%*$")+1;
+					local base_path_len = #event_name:match("/.+$");
 					local _handler = handler;
 					handler = function (event)
 						local path = event.request.path:sub(base_path_len);