From a347d63a12d0863cf848c2e4ffa891fe827e29bb Mon Sep 17 00:00:00 2001 From: Michael Wallner Date: Thu, 25 Aug 2005 12:45:31 +0000 Subject: [PATCH] - fix includes - remove tests/README.txt as it is no longer true - add parse_message test --- http_cache_api.c | 4 ++++ php_http.h | 3 +-- php_http_cache_api.h | 7 +++++-- tests/README.txt | 1 - tests/parse_message_001.phpt | 14 ++++++++++++++ 5 files changed, 24 insertions(+), 5 deletions(-) delete mode 100644 tests/README.txt create mode 100644 tests/parse_message_001.phpt diff --git a/http_cache_api.c b/http_cache_api.c index 0c96f4a..4984359 100644 --- a/http_cache_api.c +++ b/http_cache_api.c @@ -33,6 +33,10 @@ #include "php_http_send_api.h" #include "php_http_date_api.h" +#ifdef HAVE_LIBMHASH +# include +#endif + ZEND_EXTERN_MODULE_GLOBALS(http); /* {{{ char *http_etag(void *, size_t, http_send_mode) */ diff --git a/php_http.h b/php_http.h index 9137b81..f18f6d7 100644 --- a/php_http.h +++ b/php_http.h @@ -27,8 +27,7 @@ # endif # include #endif -#include "ext/standard/md5.h" -#include "ext/standard/sha1.h" + #include "phpstr/phpstr.h" extern zend_module_entry http_module_entry; diff --git a/php_http_cache_api.h b/php_http_cache_api.h index 8a9e55d..bef8cc8 100644 --- a/php_http_cache_api.h +++ b/php_http_cache_api.h @@ -18,13 +18,16 @@ #ifndef PHP_HTTP_CACHE_API_H #define PHP_HTTP_CACHE_API_H +#include "zend_ini.h" + +#include "ext/standard/md5.h" +#include "ext/standard/sha1.h" + #include "php_http_std_defs.h" #include "php_http.h" #include "php_http_api.h" #include "php_http_send_api.h" -#include "zend_ini.h" - #ifdef HAVE_LIBMHASH # include #endif diff --git a/tests/README.txt b/tests/README.txt deleted file mode 100644 index f9a1edb..0000000 --- a/tests/README.txt +++ /dev/null @@ -1 +0,0 @@ -Most of this tests fail with the standard run-tests script. diff --git a/tests/parse_message_001.phpt b/tests/parse_message_001.phpt new file mode 100644 index 0000000..c29422a --- /dev/null +++ b/tests/parse_message_001.phpt @@ -0,0 +1,14 @@ +--TEST-- +http_parse_message() +--SKIPIF-- +include 'skip.inc'; +checkuri('www.google.com'); +--FILE-- +body; +echo "Done\n"; +--EXPECTF-- +%sTEST +%sThe document has moved%s +Done -- 2.30.2