Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions src/ofxHttpUtils.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -183,13 +183,13 @@ ofxHttpResponse ofxHttpUtils::postData(string url, const ofBuffer & data, strin
istream * rs;
if(uri.getScheme()=="https"){
HTTPSClientSession * httpsSession = new HTTPSClientSession(uri.getHost(), uri.getPort());//,context);
httpsSession->setTimeout(Poco::Timespan(20,0));
httpsSession->setTimeout(Poco::Timespan(timeoutSeconds,0));
httpsSession->sendRequest(req) << data;
rs = &httpsSession->receiveResponse(res);
session = ofPtr<HTTPSession>(httpsSession);
}else{
HTTPClientSession * httpSession = new HTTPClientSession(uri.getHost(), uri.getPort());
httpSession->setTimeout(Poco::Timespan(20,0));
httpSession->setTimeout(Poco::Timespan(timeoutSeconds,0));
httpSession->sendRequest(req) << data;
rs = &httpSession->receiveResponse(res);
session = ofPtr<HTTPSession>(httpSession);
Expand Down Expand Up @@ -282,13 +282,13 @@ ofxHttpResponse ofxHttpUtils::doPostForm(ofxHttpForm & form){
istream * rs;
if(uri.getScheme()=="https"){
HTTPSClientSession * httpsSession = new HTTPSClientSession(uri.getHost(), uri.getPort());//,context);
httpsSession->setTimeout(Poco::Timespan(20,0));
httpsSession->setTimeout(Poco::Timespan(timeoutSeconds,0));
pocoForm.write(httpsSession->sendRequest(req));
rs = &httpsSession->receiveResponse(res);
session = ofPtr<HTTPSession>(httpsSession);
}else{
HTTPClientSession * httpSession = new HTTPClientSession(uri.getHost(), uri.getPort());
httpSession->setTimeout(Poco::Timespan(20,0));
httpSession->setTimeout(Poco::Timespan(timeoutSeconds,0));
pocoForm.write(httpSession->sendRequest(req));
rs = &httpSession->receiveResponse(res);
session = ofPtr<HTTPSession>(httpSession);
Expand Down