mirror of
https://github.com/php/frankenphp.git
synced 2026-03-24 00:52:11 +01:00
Uses toUnsafeChar instead
This commit is contained in:
@@ -115,7 +115,7 @@ func (mainThread *phpMainThread) start() error {
|
||||
// cache common request headers as zend_strings (HTTP_ACCEPT, HTTP_USER_AGENT, etc.)
|
||||
mainThread.commonHeaders = make(map[string]*C.zend_string, len(phpheaders.CommonRequestHeaders))
|
||||
for key, phpKey := range phpheaders.CommonRequestHeaders {
|
||||
mainThread.commonHeaders[key] = C.frankenphp_init_persistent_string(C.CString(phpKey), C.size_t(len(phpKey)))
|
||||
mainThread.commonHeaders[key] = C.frankenphp_init_persistent_string(toUnsafeChar(phpKey), C.size_t(len(phpKey)))
|
||||
}
|
||||
|
||||
// cache $_SERVER keys as zend_strings (SERVER_PROTOCOL, SERVER_SOFTWARE, etc.)
|
||||
|
||||
Reference in New Issue
Block a user