php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Doc Bug #79232 FFI+Preloading example does not work
Submitted: 2020-02-05 22:30 UTC Modified: -
Votes:3
Avg. Score:4.7 ± 0.5
Reproduced:3 of 3 (100.0%)
Same Version:3 (100.0%)
Same OS:2 (66.7%)
From: ojrask at gmail dot com Assigned:
Status: Open Package: Documentation problem
PHP Version: 7.4.2 OS:
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If this is not your bug, you can add a comment by following this link.
If this is your bug, but you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: ojrask at gmail dot com
New email:
PHP Version: OS:

 

 [2020-02-05 22:30 UTC] ojrask at gmail dot com
Description:
------------
---
From manual page: https://php.net/ffi.examples-complete
---

This example is broken.

1. When followed as is, the developer is greeted by an error that states that `opcache.preload_user` has to be set in `php.ini`, as running preloading as root is not allowed.

2. When `opcache.preload_user` is set, the example code fails with the following error:

> NOTICE: PHP message: PHP Fatal error:  Uncaught FFI\Exception: FFI::load() doesn't work in conjunction with "opcache.preload_user". Use "ffi.preload" instead. in .../preload.php:123

Or have I misunderstood something? 


Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2023-09-25 12:02 UTC] mh at hanft dot de
Still the same with PHP 8.1.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Thu Apr 25 22:01:29 2024 UTC