diff options
author | Marcello Stanisci <stanisci.m@gmail.com> | 2019-05-16 16:58:09 +0200 |
---|---|---|
committer | Marcello Stanisci <stanisci.m@gmail.com> | 2019-05-16 16:58:09 +0200 |
commit | 95933156a6d477460a20225209f556208702d55e (patch) | |
tree | e9f940ba5adfe136f1e27aa77ddc1860ff526cfd /src/lib/teah_common.h | |
parent | 8d34b22aff354f02bbd161a4e51fc8b878e32ff9 (diff) | |
download | exchange-95933156a6d477460a20225209f556208702d55e.tar.xz |
Fix compression.
The "Content-Encoding: deflate" header is now added from
within the compression routine itself, and _not_ from the
"exchange handle".
This fixed the bank-lib functions as those do not use any
exchange handle, and therefore were wrongly sending compressed
bodies without adding the mentioned HTTP header.
Diffstat (limited to 'src/lib/teah_common.h')
-rw-r--r-- | src/lib/teah_common.h | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/lib/teah_common.h b/src/lib/teah_common.h index 66937a261..c72311850 100644 --- a/src/lib/teah_common.h +++ b/src/lib/teah_common.h @@ -30,7 +30,7 @@ /** * Should we compress PUT/POST bodies with 'deflate' encoding? */ -#define COMPRESS_BODIES 0 +#define COMPRESS_BODIES 1 /** * State used for #TEAL_curl_easy_post() and @@ -43,6 +43,10 @@ struct TEAH_PostContext */ char *json_enc; + /** + * Custom headers. + */ + struct curl_slist *headers; }; |