Thanks to visit codestin.com
Credit goes to github.com

Skip to content

coredump with lpush #228

Closed
Closed
@pesiwang

Description

@pesiwang

quite strange

our users explode, and we use the redis as write queue, so we move our redis services to a new server.
then strang thing happened.

the lpush core dump

then we use the latest code of phpredis, it became ok

the version of the old code : 687903e
the latest code we downlaod is : g89bdaf2

i diff the code and can not figure why. could you help me to figure out ?

(gdb) bt
#0 0x0000000600000001 in ?? ()
#1 0x0000000000692709 in _php_stream_set_option (stream=0x2ada2d2d6638, option=12, value=0, ptrparam=0x0)

at /home/user_00/sources/php-5.3.8/main/streams/streams.c:1220

#2 0x00000000006927b0 in _php_stream_eof (stream=0x2ada2d2d6638) at /home/user_00/sources/php-5.3.8/main/streams/streams.c:685
#3 0x00002ada2acb6e1a in redis_check_eof (redis_sock=0x2ada2d2d6630)

at /home/user_00/sources/nicolasff-phpredis-687903e/library.c:32

#4 0x00002ada2acb7311 in redis_sock_read (redis_sock=0x2ada2d2d6638, buf_len=0xc)

at /home/user_00/sources/nicolasff-phpredis-687903e/library.c:132

#5 0x00002ada2acb790b in redis_long_response (ht=, return_value=0x2ada3198b130, return_value_ptr=0x0,

this_ptr=0x0, return_value_used=0, redis_sock=0x2ada2d2d6630, z_tab=0x0, ctx=0x0)
at /home/user_00/sources/nicolasff-phpredis-687903e/library.c:487

#6 0x00002ada2aca5d68 in zim_Redis_lPush (ht=2, return_value=0x2ada3198b130, return_value_ptr=0x0, this_ptr=0x2ada3198a268,

return_value_used=0) at /home/user_00/sources/nicolasff-phpredis-687903e/redis.c:1419

#7 0x00000000006f5a8a in zend_do_fcall_common_helper_SPEC (execute_data=0x2ada2d2d60b8)

at /home/user_00/sources/php-5.3.8/Zend/zend_vm_execute.h:320

#8 0x00000000006f50ec in execute (op_array=0x2ada31979b98) at /home/user_00/sources/php-5.3.8/Zend/zend_vm_execute.h:107
#9 0x00000000006cf80d in zend_execute_scripts (type=8, retval=0x0, file_count=3)

at /home/user_00/sources/php-5.3.8/Zend/zend.c:1236

#10 0x000000000067ef3d in php_execute_script (primary_file=0x7fff81a559f0) at /home/user_00/sources/php-5.3.8/main/main.c:2284
#11 0x000000000075c480 in main (argc=3, argv=) at /home/user_00/sources/php-5.3.8/sapi/fpm/fpm/fpm_main.c:1902

(gdb) f 6
#6 0x00002ada2aca5d68 in zim_Redis_lPush (ht=2, return_value=0x2ada3198b130, return_value_ptr=0x0, this_ptr=0x2ada3198a268,

return_value_used=0) at /home/user_00/sources/nicolasff-phpredis-687903e/redis.c:1419

1419 redis_long_response(INTERNAL_FUNCTION_PARAM_PASSTHRU, redis_sock, NULL, NULL);
(gdb) p (RedisSock *)redis_sock
$7 = {stream = 0x2ada2d2d6638, host = 0x2ada3198b130 "", port = 0, timeout = 0, failed = 0, status = 0, persistent = 0,
persistent_id = 0x0, serializer = 0, prefix = 0x2ada31906e38 "\002T^2
", prefix_len = 0, mode = ATOMIC, head = 0x2ada290bb438,
current = 0x2ada317d8e28, pipeline_head = 0x0, pipeline_current = 0x2ada2d2d66a0}
(gdb) p (char *)0x2ada3198b130
$8 = 0x2ada3198b130 ""
(gdb) p *(char *)0x2ada3198b130
$9 = 0 '\0'

my eamil : [email protected]

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions