Skip to content

Commit 482d167

Browse files
committed
MFH: support stat cache of webserver (like apache does)
1 parent 63f6f50 commit 482d167

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

sapi/nsapi/nsapi.c

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -809,6 +809,13 @@ static int php_nsapi_startup(sapi_module_struct *sapi_module)
809809
return SUCCESS;
810810
}
811811

812+
static struct stat* sapi_nsapi_get_stat(TSRMLS_D)
813+
{
814+
return request_stat_path(
815+
SG(request_info).path_translated,
816+
((nsapi_request_context *)SG(server_context))->rq
817+
);
818+
}
812819

813820
static sapi_module_struct nsapi_sapi_module = {
814821
"nsapi", /* name */
@@ -822,7 +829,7 @@ static sapi_module_struct nsapi_sapi_module = {
822829

823830
sapi_nsapi_ub_write, /* unbuffered write */
824831
sapi_nsapi_flush, /* flush */
825-
NULL, /* get uid */
832+
sapi_nsapi_get_stat, /* get uid/stat */
826833
NULL, /* getenv */
827834

828835
php_error, /* error handler */

0 commit comments

Comments
 (0)