Commit 5cd5198e authored by Slava Monich's avatar Slava Monich

[mms-lib] Set HTTP Connection header to "close". Fixes MER#1731

We never reuse the connection and operators usually reply with
"Connection: close" anyway. Also, some carriers actually require
Connection to be "close"
parent 849b3d0c
/* /*
* Copyright (C) 2013-2016 Jolla Ltd. * Copyright (C) 2013-2017 Jolla Ltd.
* Contact: Slava Monich <slava.monich@jolla.com> * Contact: Slava Monich <slava.monich@jolla.com>
* *
* This program is free software; you can redistribute it and/or modify * This program is free software; you can redistribute it and/or modify
...@@ -212,6 +212,8 @@ mms_http_transfer_new( ...@@ -212,6 +212,8 @@ mms_http_transfer_new(
soup_message_set_flags(tx->message, soup_message_set_flags(tx->message,
SOUP_MESSAGE_NO_REDIRECT | SOUP_MESSAGE_NO_REDIRECT |
SOUP_MESSAGE_NEW_CONNECTION); SOUP_MESSAGE_NEW_CONNECTION);
soup_message_headers_append(tx->message->request_headers,
"Connection", "close");
if (cfg->uaprof && cfg->uaprof[0]) { if (cfg->uaprof && cfg->uaprof[0]) {
const char* uaprof_header = "x-wap-profile"; const char* uaprof_header = "x-wap-profile";
GVERBOSE("%s %s", uaprof_header, cfg->uaprof); GVERBOSE("%s %s", uaprof_header, cfg->uaprof);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment