You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
gentoo-overlay/app-admin/conky/files/conky-1.11.6-fpermissive.patch

30 lines
1.4 KiB

--- old/src/conky.cc 2021-01-24 17:05:43.361378726 +0100
+++ new/src/conky.cc 2021-01-24 17:05:49.055378611 +0100
@@ -317,17 +321,22 @@
static FILE *append_fpointer = nullptr;
#ifdef BUILD_HTTP
+#ifdef MHD_YES
+/* older API */
+#define MHD_Result int
+#endif /* MHD_YES */
std::string webpage;
struct MHD_Daemon *httpd;
static conky::simple_config_setting<bool> http_refresh("http_refresh", false,
true);
-int sendanswer(void *cls, struct MHD_Connection *connection, const char *url,
- const char *method, const char *version, const char *upload_data,
- size_t *upload_data_size, void **con_cls) {
+MHD_Result sendanswer(void *cls, struct MHD_Connection *connection,
+ const char *url, const char *method, const char *version,
+ const char *upload_data, size_t *upload_data_size,
+ void **con_cls) {
struct MHD_Response *response = MHD_create_response_from_buffer(
webpage.length(), (void *)webpage.c_str(), MHD_RESPMEM_PERSISTENT);
- int ret = MHD_queue_response(connection, MHD_HTTP_OK, response);
+ MHD_Result ret = MHD_queue_response(connection, MHD_HTTP_OK, response);
MHD_destroy_response(response);
if (cls || url || method || version || upload_data || upload_data_size ||
con_cls) {} // make compiler happy