略微加速

PHP官方手册 - 互联网笔记

PHP - Manual: pcntl_errno

2024-12-22

pcntl_errno

(PHP 5 >= 5.3.4, PHP 7, PHP 8)

pcntl_errno别名 pcntl_get_last_error()

说明

此函数是该函数的别名: pcntl_get_last_error()

add a noteadd a note

User Contributed Notes 1 note

up
-1
renmengyang567 at gmail dot com
3 years ago
<explain>
This example installs an alarm signal, but the callback function does not exist,This will set the last error. Then we will print out the last error.

<?php
set_error_handler
(function(){});
pcntl_signal(SIGALRM,'sig_handler',false);
print 
'Your error returned was (Code):'.pcntl_get_last_error().PHP_EOL;
print 
'Your error info:'.pcntl_strerror(pcntl_get_last_error()).PHP_EOL;

官方地址:https://www.php.net/manual/en/function.pcntl-errno.php

北京半月雨文化科技有限公司.版权所有 京ICP备12026184号-3