Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

zltime::reportPerf returns null in production, causes attempt to access NULL as array #2

Open
Miguel-Serejo opened this issue Mar 28, 2024 · 2 comments

Comments

@Miguel-Serejo
Copy link

When zl_mode is set to prod with default configs (debugLog=false and debugLogOnFault=false), the debugger will call $temp = ztime::reportPerf(memory_get_usage() - $zl_debugMem);, which will return null, and then attempt to access $temp['report'] and $temp['time']

This causes two warnings to trigger on every page load:
Warning: Trying to access array offset on null in zerolith/classes/zl.php on line 676
Warning: Trying to access array offset on null in zerolith/classes/zl.php on line 677

Only userland "fix" currently is to change zl_mode to something other than prod.

@courtesysoft
Copy link
Owner

Thanks for letting me know about this bug, working on a fix as we speak

@courtesysoft
Copy link
Owner

Fix will be in the next update - v1.18, thanks for reporting this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants