#endif
+#if !defined(CURLINFO_RESONSE_CODE) && defined(CURLINFO_HTTP_CODE)
+#define CURLINFO_RESONSE_CODE CURLINFO_HTTP_CODE
+#endif
ZEND_DECLARE_MODULE_GLOBALS(http)
{
/* CURLINFO_EFFECTIVE_URL = CURLINFO_STRING +1, */
CASE(EFFECTIVE_URL);
+#ifdef CURLINFO_RESONSE_CODE
/* CURLINFO_RESPONSE_CODE = CURLINFO_LONG +2, */
CASE(RESPONSE_CODE);
+#endif
/* CURLINFO_TOTAL_TIME = CURLINFO_DOUBLE +3, */
CASE(TOTAL_TIME);
/* CURLINFO_NAMELOOKUP_TIME = CURLINFO_DOUBLE +4, */
CASE(PRIVATE);
/* CURLINFO_HTTP_CONNECTCODE = CURLINFO_LONG +22, */
CASE(HTTP_CONNECTCODE);
+#ifdef CURLINFO_HTTPAUTH_AVAIL
/* CURLINFO_HTTPAUTH_AVAIL = CURLINFO_LONG +23, */
CASE(HTTPAUTH_AVAIL);
+#endif
+#ifdef CURLINFO_PROXYAUTH_AVAIL
/* CURLINFO_PROXYAUTH_AVAIL = CURLINFO_LONG +24, */
- CASE(PROXYAUTH_AVAIL);
+ CASE(PROXYAUTH_AVAIL);
+#endif
}
#undef CASE
return NULL;
#define INFO(I) http_curl_getinfo_ex(ch, CURLINFO_ ##I , &array)
/* CURLINFO_EFFECTIVE_URL = CURLINFO_STRING +1, */
INFO(EFFECTIVE_URL);
+#ifdef CURLINFO_RESONSE_CODE
/* CURLINFO_RESPONSE_CODE = CURLINFO_LONG +2, */
INFO(RESPONSE_CODE);
+#endif
/* CURLINFO_TOTAL_TIME = CURLINFO_DOUBLE +3, */
INFO(TOTAL_TIME);
/* CURLINFO_NAMELOOKUP_TIME = CURLINFO_DOUBLE +4, */
INFO(PRIVATE);
/* CURLINFO_HTTP_CONNECTCODE = CURLINFO_LONG +22, */
INFO(HTTP_CONNECTCODE);
+#ifdef CURLINFO_HTTPAUTH_AVAIL
/* CURLINFO_HTTPAUTH_AVAIL = CURLINFO_LONG +23, */
INFO(HTTPAUTH_AVAIL);
+#endif
+#ifdef CURLINFO_PROXYAUTH_AVAIL
/* CURLINFO_PROXYAUTH_AVAIL = CURLINFO_LONG +24, */
INFO(PROXYAUTH_AVAIL);
+#endif
#undef INFO
}
/* }}} */