kphp icon indicating copy to clipboard operation
kphp copied to clipboard

cli version not working (uses all memory then dumps core)

Open pixall opened this issue 3 years ago • 0 comments

I'm trying to do simple "hello world" script using kphp (latest version compiled from git). If I run kphp with "-m server" option, produced binary can be started and I can get my "hello world" via HTTP successfully. Unfortunately if I run kphp with "-m cli", produced binary is not working. After starting initializations, it consumes all available memory and then crashes with core dump, before starting my "hello world" code.

I was trying to find the problem, and it seems that it works until server/php-engine.cpp line 1466 is reached: prepare_rpc_query_raw(i, q, qsize, crc32c_partial); After calling this function, all memory is eaten and core dumped, next line is not reached. Called part of code is related to RPC, and I'm really not sure if simple CLI "hello world" should be using RPC. Should it?

pixall avatar Mar 20 '22 03:03 pixall