Skip to content

Commit

Permalink
Fixed apache module compilation error issue and set header issue
Browse files Browse the repository at this point in the history
  • Loading branch information
sumeetchhetri committed Jan 10, 2017
1 parent 22614b8 commit c80feeb
Showing 1 changed file with 14 additions and 4 deletions.
18 changes: 14 additions & 4 deletions modules/apache_mod_ffeadcpp/mod_ffeadcpp.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -45,15 +45,25 @@
#include <signal.h>
#include <fcntl.h>
#include <queue>
#ifdef INC_COMP
#include "ComponentGen.h"
#include "ComponentHandler.h"
#include "AppContext.h"
#endif
#ifdef INC_MSGH
#include "MessageHandler.h"
#endif
#ifdef INC_MI
#include "MethodInvoc.h"
#endif
#ifdef INC_COMP
#include "AppContext.h"
#endif
#include "Logger.h"
#include "ConfigurationHandler.h"
#include "ServiceTask.h"
#include "PropFileReader.h"
#include "XmlParseException.h"
#include "MessageHandler.h"
#include "MethodInvoc.h"
#undef strtoul
#ifdef WINDOWS
#include <direct.h>
Expand Down Expand Up @@ -217,7 +227,7 @@ static int mod_ffeadcpp_method_handler (request_rec *r)

for (int var = 0; var < (int)respo->getCookies().size(); var++)
{
apr_table_setn(r->headers_out, "Set-Cookie", respo->getCookies().at(var).c_str());
apr_table_set(r->headers_out, "Set-Cookie", respo->getCookies().at(var).c_str());
}

if(respo->isDone()) {
Expand All @@ -228,7 +238,7 @@ static int mod_ffeadcpp_method_handler (request_rec *r)
if(StringUtil::toLowerCopy(it->first)==StringUtil::toLowerCopy(HttpResponse::ContentType)) {
ap_set_content_type(r, it->second.c_str());
} else {
apr_table_setn(r->headers_out, it->first.c_str(), it->second.c_str());
apr_table_set(r->headers_out, it->first.c_str(), it->second.c_str());
}
}
ap_rprintf(r, data.c_str(), data.length());
Expand Down

0 comments on commit c80feeb

Please # to comment.