]> granicus.if.org Git - ejabberd/commitdiff
Properly handle HEAD request in mod_http_bind (this fixes EJAB-1538)
authorPaweł Chmielowski <pchmielowski@process-one.net>
Fri, 6 Apr 2012 09:47:38 +0000 (11:47 +0200)
committerPaweł Chmielowski <pchmielowski@process-one.net>
Fri, 6 Apr 2012 09:47:38 +0000 (11:47 +0200)
src/web/mod_http_bind.erl

index 5833d7f61aefdee967d97b16c556ca0701a2da7b..99409450c11068732b7cd0ad997f461d9662e275 100644 (file)
@@ -74,6 +74,8 @@ process([], #request{method = 'GET',
 process([], #request{method = 'OPTIONS',
                      data = []}) ->
     {200, ?OPTIONS_HEADER, []};
+process([], #request{method = 'HEAD'}) ->
+    {200, ?HEADER, []};
 process(_Path, _Request) ->
     ?DEBUG("Bad Request: ~p", [_Request]),
     {400, ?HEADER, {xmlelement, "h1", [],