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
websocket下用定时器发送断错误 #280
Comments
贴一下你的代码 |
代码片段: |
你用法有错误,必须在 回调函数中调用 addtimer |
1.7.5之后onStart回调中不再支持定时器 看文档有这个描述,我的代码有onStart的回调: |
好,我知道了,谢谢。 |
websocket下用定时器发送断错误
(gdb) bt
#0 zif_swoole_server_addtimer (ht=1, return_value=0x7fd3c1c76f08, return_value_ptr=, this_ptr=0x7fd3c1a9e698, return_value_used=0) at /root/swoole-src-swoole-1.7.17-stable/swoole_server.c:2291
#1 0x0000000000897065 in zend_do_fcall_common_helper_SPEC (execute_data=) at /root/php-5.6.9/Zend/zend_vm_execute.h:560
#2 0x0000000000886bc0 in execute_ex (execute_data=0x7fd3c1c3aa68) at /root/php-5.6.9/Zend/zend_vm_execute.h:363
#3 0x0000000000818949 in zend_execute_scripts (type=8, retval=0x0, file_count=3) at /root/php-5.6.9/Zend/zend.c:1341
#4 0x00000000007b844a in php_execute_script (primary_file=0x7ffff3d62d50) at /root/php-5.6.9/main/main.c:2597
#5 0x00000000008be78c in do_cli (argc=2, argv=0x13fab10) at /root/php-5.6.9/sapi/cli/php_cli.c:994
#6 0x00000000008bef28 in main (argc=2, argv=0x13fab10) at /root/php-5.6.9/sapi/cli/php_cli.c:1378
(gdb)
(gdb) f 1
#1 0x0000000000897065 in zend_do_fcall_common_helper_SPEC (execute_data=) at /root/php-5.6.9/Zend/zend_vm_execute.h:560
560 zend_execute_internal(execute_data, NULL, RETURN_VALUE_USED(opline) TSRMLS_CC);
(gdb)
(gdb) f 0
#0 zif_swoole_server_addtimer (ht=1, return_value=0x7fd3c1c76f08, return_value_ptr=, this_ptr=0x7fd3c1a9e698, return_value_used=0) at /root/swoole-src-swoole-1.7.17-stable/swoole_server.c:2291
2291 /root/swoole-src-swoole-1.7.17-stable/swoole_server.c: 没有那个文件或目录.
in /root/swoole-src-swoole-1.7.17-stable/swoole_server.c
(gdb)
The text was updated successfully, but these errors were encountered: