X-Git-Url: https://git.m6w6.name/?p=m6w6%2Fext-http;a=blobdiff_plain;f=http_send_api.c;h=0db19b36a9c509640b7ff644fd46c21208eda75e;hp=62660359026f03581012666a8a1add9101dae87a;hb=4fcbd8e8ae31611c5197ff2369673b5939fc2b80;hpb=3b81f44e1506fa9356db0b630401f8ff95e9d89a diff --git a/http_send_api.c b/http_send_api.c index 6266035..0db19b3 100644 --- a/http_send_api.c +++ b/http_send_api.c @@ -12,15 +12,11 @@ /* $Id$ */ -#ifdef HAVE_CONFIG_H -# include "config.h" -#endif - +#define HTTP_WANT_SAPI #define HTTP_WANT_ZLIB #define HTTP_WANT_MAGIC #include "php_http.h" -#include "SAPI.h" #include "php_streams.h" #include "ext/standard/php_lcg.h" @@ -363,7 +359,7 @@ PHP_HTTP_API STATUS _http_send_ex(const void *data_ptr, size_t data_size, http_s char boundary_str[32], range_header_str[256]; size_t boundary_len, range_header_len; - boundary_len = snprintf(boundary_str, lenof(boundary_str), "%lu%0.9f", (ulong) time(NULL), (float) php_combined_lcg(TSRMLS_C)); + boundary_len = snprintf(boundary_str, lenof(boundary_str), "%lu%0.9f", (ulong) HTTP_GET_REQUEST_TIME(), (float) php_combined_lcg(TSRMLS_C)); range_header_len = snprintf(range_header_str, lenof(range_header_str), "Content-Type: multipart/byteranges; boundary=%s", boundary_str); http_send_status_header_ex(206, range_header_str, range_header_len, 1);