Show
Ignore:
Timestamp:
08/26/10 22:11:40 (21 months ago)
Author:
Antti-Juhani Kaijanaho <ajk@…>
Children:
28939ac15506b95f59142a06b7d6794a801f8198
Parents:
654bb6066f0a41076097ffd2498c04805e4d7276
git-committer:
Antti-Juhani Kaijanaho <ajk@…> (08/26/10 22:11:40)
Message:

[http::request] Handle POST form Content-Types with parameters

Signed-off-by: Antti-Juhani Kaijanaho <ajk@…>

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • http/request.cc

    r751fac6 r19a2630  
    115115        { 
    116116                if (form_data_ready) return; 
    117                 if (method != "POST" || 
    118                     get_header("content-type") 
    119                     == "application/x-www-form-urlencoded") 
     117                std::string ct = get_header("content-type"); 
     118                size_t sc = ct.find(';'); 
     119                if (sc != std::string::npos) ct.erase(sc); 
     120                if (method != "POST" || ct == "application/x-www-form-urlencoded") 
    120121                { 
    121122                        std::string bd = method == "POST"