Fix compiling --without-libcurl.

Previously <curl/curl.h> was included even if compiled --without-libcurl.
This can fail when libcurl headers are not there. This commit guards this
include by checks for HAVE_LIBCURL.
pull/1701/head
Hadi Moshayedi 2017-10-12 18:23:24 -04:00
parent 4832abc7cb
commit 873fd1e7ff
1 changed files with 4 additions and 4 deletions

View File

@ -10,6 +10,10 @@
#include "postgres.h"
bool EnableStatisticsCollection = true; /* send basic usage statistics to Citus */
#if HAVE_LIBCURL
#include <curl/curl.h>
#include <sys/utsname.h>
@ -21,10 +25,6 @@
#include "lib/stringinfo.h"
#include "utils/json.h"
bool EnableStatisticsCollection = true; /* send basic usage statistics to Citus */
#if HAVE_LIBCURL
static uint64 NextPow2(uint64 n);
static uint64 ClusterSize(List *distributedTableList);
static bool SendHttpPostJsonRequest(const char *url, const char *postFields, long