From f035b13c64a5f54884a71df3de53b608d00f2f34 Mon Sep 17 00:00:00 2001
From: Vadim Sadokhov <65451602+astrophysik@users.noreply.github.com>
Date: Wed, 6 Dec 2023 19:46:03 +0300
Subject: [PATCH] add curlopt_accept_encoding (#951)

---
 builtin-functions/_functions.txt | 1 +
 runtime/curl.cpp                 | 1 +
 2 files changed, 2 insertions(+)

diff --git a/builtin-functions/_functions.txt b/builtin-functions/_functions.txt
index 3630fc46fc..16077a9bc4 100644
--- a/builtin-functions/_functions.txt
+++ b/builtin-functions/_functions.txt
@@ -1270,6 +1270,7 @@ define('CURLOPT_TCP_KEEPALIVE', 200123);
 define('CURLOPT_TCP_KEEPIDLE', 200124);
 define('CURLOPT_TCP_KEEPINTVL', 200125);
 define('CURLOPT_PRIVATE', 200126);
+define('CURLOPT_ACCEPT_ENCODING', 200127);
 
 define('CURLPROXY_HTTP', 400000);
 define('CURLPROXY_HTTP_1_0', 400001);
diff --git a/runtime/curl.cpp b/runtime/curl.cpp
index 1655ab9f98..5d035e4a2e 100644
--- a/runtime/curl.cpp
+++ b/runtime/curl.cpp
@@ -583,6 +583,7 @@ bool curl_setopt(EasyContext *easy_context, int64_t option, const mixed &value)
       {CURLOPT_TCP_KEEPIDLE,         long_option_setter},
       {CURLOPT_TCP_KEEPINTVL,        long_option_setter},
       {CURLOPT_PRIVATE,              private_option_setter},
+      {CURLOPT_ACCEPT_ENCODING,      string_option_setter},
     });
 
   constexpr size_t CURLOPT_OPTION_OFFSET = 200000;