diff options
| -rw-r--r-- | ext/standard/head.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/ext/standard/head.c b/ext/standard/head.c index 87994bc369..6223ea8d93 100644 --- a/ext/standard/head.c +++ b/ext/standard/head.c @@ -183,7 +183,11 @@ PHP_FUNCTION(headers_sent) ZVAL_LONG(arg2, line); case 1: zval_dtor(arg1); - ZVAL_STRING(arg1, file, 1); + if (file) { + ZVAL_STRING(arg1, file, 1); + } else { + ZVAL_STRING(arg1, "", 1); + } break; } |
