com php-src: change server->phpdbg: phpdbg.c
| From: | Bob Weinand | Date: | Sat, 09 Nov 2013 22:47:39 +0000 |
| Subject: | com php-src: change server->phpdbg: phpdbg.c | ||
| Groups: | php.cvs | ||
| Request: | Send a blank email to php-cvs+get-75243@lists.php.net to get a copy of this message | ||
Commit: 60ee0cc74cbe43aa2452c97b1c687320d41b4c59
Author: krakjoe <joe.watkins@live.co.uk> Sat, 9 Nov 2013 22:47:39 +0000
Parents: 2fee7dce773dc365ef720d41568bcc2914065413
Branches: PHP-5.6
Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=60ee0cc74cbe43aa2452c97b1c687320d41b4c59
Log:
change server->phpdbg
Changed paths:
M phpdbg.c
Diff:
diff --git a/phpdbg.c b/phpdbg.c
index ba1b0a3..9223824 100644
--- a/phpdbg.c
+++ b/phpdbg.c
@@ -31,9 +31,9 @@
#include "php_main.h"
-static zend_module_entry sapi_server_module_entry = {
+static zend_module_entry sapi_phpdbg_module_entry = {
STANDARD_MODULE_HEADER,
- "server",
+ "phpdbg",
NULL,
NULL,
NULL,
@@ -44,20 +44,20 @@ static zend_module_entry sapi_server_module_entry = {
STANDARD_MODULE_PROPERTIES
};
-static inline int php_sapi_server_module_startup(sapi_module_struct *module) { /* {{{ */
- if (php_module_startup(module, &sapi_server_module_entry, 1) == FAILURE) {
+static inline int php_sapi_phpdbg_module_startup(sapi_module_struct *module) { /* {{{ */
+ if (php_module_startup(module, &sapi_phpdbg_module_entry, 1) == FAILURE) {
return FAILURE;
}
return SUCCESS;
} /* }}} */
-/* {{{ sapi_module_struct server_sapi_module
+/* {{{ sapi_module_struct phpdbg_sapi_module
*/
-static sapi_module_struct server_sapi_module = {
- "server", /* name */
- "SAPI server", /* pretty name */
+static sapi_module_struct phpdbg_sapi_module = {
+ "phpdbg", /* name */
+ "phpdbg", /* pretty name */
- php_sapi_server_module_startup, /* startup */
+ php_sapi_phpdbg_module_startup, /* startup */
php_module_shutdown_wrapper, /* shutdown */
NULL, /* activate */
@@ -100,9 +100,16 @@ int main(int argc, char **argv) { /* {{{ */
}
#endif
- sapi_startup(&server_sapi_module);
+#ifdef PHP_WIN32
+ _fmode = _O_BINARY; /*sets default for file streams to binary */
+ setmode(_fileno(stdin), O_BINARY); /* make the stdio mode be binary */
+ setmode(_fileno(stdout), O_BINARY); /* make the stdio mode be binary */
+ setmode(_fileno(stderr), O_BINARY); /* make the stdio mode be binary */
+#endif
+
+ sapi_startup(&phpdbg_sapi_module);
- if (server_sapi_module.startup(&server_sapi_module) == SUCCESS)
+ if (phpdbg_sapi_module.startup(&phpdbg_sapi_module) == SUCCESS)
{
zend_activate(TSRMLS_C);