summaryrefslogtreecommitdiff
path: root/sapi/cli/php_cli.c
diff options
context:
space:
mode:
authorAntony Dovgal <tony2001@php.net>2006-06-27 08:27:10 +0000
committerAntony Dovgal <tony2001@php.net>2006-06-27 08:27:10 +0000
commit6c52ec131980e8ae11cd578aa60187947607f022 (patch)
tree8254aaba680c1742fb619846988da42610d62a64 /sapi/cli/php_cli.c
parentaaa1d62614b1ffab4c7f698fa1f3a2c4746b379f (diff)
downloadphp-git-6c52ec131980e8ae11cd578aa60187947607f022.tar.gz
MFH: fix #37920 (compilation problems on z/OS)
Diffstat (limited to 'sapi/cli/php_cli.c')
-rw-r--r--sapi/cli/php_cli.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/sapi/cli/php_cli.c b/sapi/cli/php_cli.c
index 2e6e8d6c3a..a7e3288be2 100644
--- a/sapi/cli/php_cli.c
+++ b/sapi/cli/php_cli.c
@@ -545,12 +545,12 @@ static int cli_seek_file_begin(zend_file_handle *file_handle, char *script_file,
/* #!php support */
c = fgetc(file_handle->handle.fp);
if (c == '#') {
- while (c != 10 && c != 13) {
+ while (c != '\n' && c != '\r') {
c = fgetc(file_handle->handle.fp); /* skip to end of line */
}
/* handle situations where line is terminated by \r\n */
- if (c == 13) {
- if (fgetc(file_handle->handle.fp) != 10) {
+ if (c == '\r') {
+ if (fgetc(file_handle->handle.fp) != '\n') {
long pos = ftell(file_handle->handle.fp);
fseek(file_handle->handle.fp, pos - 1, SEEK_SET);
}