]> granicus.if.org Git - php/commitdiff
Fixed bug #20035. ZE now allows us to pass the current line position by
authorIlia Alshanetsky <iliaa@php.net>
Tue, 5 Nov 2002 22:04:12 +0000 (22:04 +0000)
committerIlia Alshanetsky <iliaa@php.net>
Tue, 5 Nov 2002 22:04:12 +0000 (22:04 +0000)
setting zend_lineno to (current_line * -1).

sapi/cgi/cgi_main.c
sapi/cli/php_cli.c
sapi/fastcgi/fastcgi.c

index 6dd85e20fb72fcca20e49f1fdfdb23681bc2f048..2d707d7e43cf5f1cfc5d2785c1c6a2103157c066 100644 (file)
@@ -1119,7 +1119,7 @@ consult the installation file that came with this distribution, or visit \n\
                                while (c != 10 && c != 13) {
                                        c = fgetc(file_handle.handle.fp);       /* skip to end of line */
                                }
-                               CG(zend_lineno)++;
+                               CG(zend_lineno) = -2;
                        } else {
                                rewind(file_handle.handle.fp);
                        }
index 28a06a1733936d7f82f9a861946369289ef33bcc..c986ee3dc793749aa3612f890657b05c7b455a8b 100644 (file)
@@ -652,7 +652,7 @@ int main(int argc, char *argv[])
                                while (c != 10 && c != 13) {
                                        c = fgetc(file_handle.handle.fp);       /* skip to end of line */
                                }
-                               CG(zend_lineno)++;
+                               CG(zend_lineno) = -2;
                        } else {
                                rewind(file_handle.handle.fp);
                        }
index 23fd8c0aec2d9e5122029513cb9d8e6a8fcac3b7..f9430943e1ea128033ae789e2c7d6c437e31e497 100644 (file)
@@ -237,7 +237,7 @@ static void fastcgi_module_main(TSRMLS_D)
                        while (c != 10 && c != 13) {
                                c = fgetc(file_handle.handle.fp);       /* skip to end of line */
                        }
-                       CG(zend_lineno)++;
+                       CG(zend_lineno) = -2;
                } else {
                        rewind(file_handle.handle.fp);
                }