Skip to content

Commit 67a15cf

Browse files
committed
ext/standard/head.c: Change return type of php_header() to bool
1 parent 2297e50 commit 67a15cf

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

ext/standard/head.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -67,12 +67,12 @@ PHP_FUNCTION(header_remove)
6767
}
6868
/* }}} */
6969

70-
PHPAPI int php_header(void)
70+
PHPAPI bool php_header(void)
7171
{
7272
if (sapi_send_headers()==FAILURE || SG(request_info).headers_only) {
73-
return 0; /* don't allow output */
73+
return false; /* don't allow output */
7474
} else {
75-
return 1; /* allow output */
75+
return true; /* allow output */
7676
}
7777
}
7878

ext/standard/head.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@
2727

2828
extern PHP_RINIT_FUNCTION(head);
2929

30-
PHPAPI int php_header(void);
30+
PHPAPI bool php_header(void);
3131
PHPAPI zend_result php_setcookie(zend_string *name, zend_string *value, time_t expires,
3232
zend_string *path, zend_string *domain, bool secure, bool httponly,
3333
zend_string *samesite, bool url_encode);

0 commit comments

Comments
 (0)