From 13e67642fa1410fcc3840d2ea283c8bf4730133d Mon Sep 17 00:00:00 2001 From: Zeev Suraski Date: Thu, 16 Sep 1999 22:15:43 +0000 Subject: [PATCH] Generalize SAPI a bit --- Makefile.in | 2 +- ext/standard/info.c | 2 +- main/php_content_types.c | 14 ++++++++++++++ 3 files changed, 16 insertions(+), 2 deletions(-) create mode 100644 main/php_content_types.c diff --git a/Makefile.in b/Makefile.in index 2cd1acbc29..dc63bfa22c 100644 --- a/Makefile.in +++ b/Makefile.in @@ -73,7 +73,7 @@ LIBOBJS=@LIBOBJS@ SOURCE = main.c internal_functions.c snprintf.c php3_sprintf.c \ configuration-parser.c configuration-scanner.c request_info.c \ safe_mode.c fopen-wrappers.c php3_realpath.c alloca.c output.c \ - php_ini.c SAPI.c cgi_main.c rfc1867.c dlist.c + php_ini.c SAPI.c cgi_main.c rfc1867.c dlist.c rfc1867.c OBJS = $(SOURCE:.c=.o) $(LIBOBJS) PHPLIBS = -Llibzend -lzend -Lext -lphpext LIBS = $(PHPLIBS) $(EXTRA_LIBS) @LIBS@ diff --git a/ext/standard/info.c b/ext/standard/info.c index 5388c02d99..e2f4a8d20f 100644 --- a/ext/standard/info.c +++ b/ext/standard/info.c @@ -213,7 +213,7 @@ PHPAPI void php_print_info(int flag) } PUTS("\"]"); if ((*tmp)->type == IS_ARRAY) { - PUTS("
");
+					PUTS("
");
 					zend_print_zval_r(*tmp, 0);
 					PUTS("
"); } else { diff --git a/main/php_content_types.c b/main/php_content_types.c new file mode 100644 index 0000000000..8ee79dc0e5 --- /dev/null +++ b/main/php_content_types.c @@ -0,0 +1,14 @@ +#include "php.h" +#include "SAPI.h" +#include "rfc1867.h" + +static sapi_post_content_type_reader php_post_content_types[] = { + { MULTIPART_CONTENT_TYPE, sizeof(MULTIPART_CONTENT_TYPE)-1, rfc1867_post_reader }, + { NULL, 0, NULL } +} + +int php_startup_SAPI_content_types() +{ + sapi_register_post_readers(php_post_content_types); + return SUCCESS; +} -- 2.40.0