Edit report at http://bugs.php.net/bug.php?id=51372&edit=1

 ID:               51372
 User updated by:  daynejordan at gmail dot com
 Reported by:      daynejordan at gmail dot com
 Summary:          php5-ffmpeg extension causes php to coredump
 Status:           Bogus
 Type:             Bug
 Package:          Unknown/Other Function
 Operating System: FreeBSD-7.3
 PHP Version:      5.2.13

 New Comment:

I disabled suhosin and enabled debug, recompiled, still cores, here is
the full backtrace:



server2# gdb /usr/local/bin/php php.core

GNU gdb 6.1.1 [FreeBSD]

Copyright 2004 Free Software Foundation, Inc.

This GDB was configured as "i386-marcel-freebsd"...

Core was generated by `php'.

Program terminated with signal 11, Segmentation fault.

Reading symbols from /lib/libcrypt.so.4...done.

Loaded symbols for /lib/libcrypt.so.4

Reading symbols from /usr/lib/librt.so.1...done.

Loaded symbols for /usr/lib/librt.so.1

Reading symbols from /lib/libm.so.5...done.

Loaded symbols for /lib/libm.so.5

Reading symbols from /usr/local/lib/libxml2.so.5...done.

Loaded symbols for /usr/local/lib/libxml2.so.5

Reading symbols from /lib/libz.so.4...done.

Loaded symbols for /lib/libz.so.4

Reading symbols from /usr/local/lib/libiconv.so.3...done.

Loaded symbols for /usr/local/lib/libiconv.so.3

Reading symbols from /lib/libc.so.7...done.

Loaded symbols for /lib/libc.so.7

Reading symbols from /libexec/ld-elf.so.1...done.

Loaded symbols for /libexec/ld-elf.so.1

#0  0x286a8480 in ?? ()

(gdb) bt full

#0  0x286a8480 in ?? ()

No symbol table info available.

#1  0x2861e15b in pthread_once () from /lib/libc.so.7

No symbol table info available.

#2  0x283ac092 in xmlIsMainThread () from /usr/local/lib/libxml2.so.5

No symbol table info available.

#3  0x283ab647 in __xmlLastError () from /usr/local/lib/libxml2.so.5

No symbol table info available.

#4  0x28337847 in xmlResetLastError () from /usr/local/lib/libxml2.so.5

No symbol table info available.

#5  0x2833e82f in xmlCleanupParser () from /usr/local/lib/libxml2.so.5

No symbol table info available.

#6  0x08092f39 in php_libxml_shutdown () at
/usr/ports/lang/php5/work/php-5.2.12/ext/libxml/libxml.c:589

No locals.

#7  0x0809344b in zm_shutdown_libxml (type=1, module_number=2) at
/usr/ports/lang/php5/work/php-5.2.12/ext/libxml/libxml.c:660

No locals.

#8  0x081a2100 in module_destructor (module=0x2876d0a0) at
/usr/ports/lang/php5/work/php-5.2.12/Zend/zend_API.c:1924

No locals.

#9  0x081a77ef in zend_hash_apply_deleter (ht=0x82bfd40, p=0x28771160)
at /usr/ports/lang/php5/work/php-5.2.12/Zend/zend_hash.c:611

        retval = (Bucket *) 0x0

#10 0x081a797e in zend_hash_graceful_reverse_destroy (ht=0x82bfd40) at
/usr/ports/lang/php5/work/php-5.2.12/Zend/zend_hash.c:646

        p = (Bucket *) 0x28771160

#11 0x0819a7de in zend_shutdown () at
/usr/ports/lang/php5/work/php-5.2.12/Zend/zend.c:733

No locals.

#12 0x081467cf in php_module_shutdown () at
/usr/ports/lang/php5/work/php-5.2.12/main/main.c:1918

        module_number = 0

#13 0x0821cf73 in main (argc=2, argv=0xbfbfec28) at
/usr/ports/lang/php5/work/php-5.2.12/sapi/cli/php_cli.c:1360

        exit_status = 0

        c = 118

        file_handle = {type = 0 '\0', filename = 0xbfbfeb88 "", 

  opened_path = 0x282ac3f3
"\211Æë\220\213MÜ\017¶A\fÀè\004<\002tP\215\203¬\003", handle =
{fd = -1077941384, fp = 0xbfbfeb78, 

    stream = {handle = 0xbfbfeb78, reader = 0x282de030, closer = 0x1,
fteller = 0x282af2df <dlopen+4239>, interactive = 0}}, 

  free_filename = 100 'd'}

        behavior = 1

        reflection_what = 0x0

        orig_optind = 1

        orig_optarg = 0x0

        arg_free = 0x0

        arg_excp = (char **) 0xbfbfeb40

        script_file = 0x0

        interactive = 0

        module_started = 1

        request_started = 1

        lineno = 0

        exec_direct = 0x0

        exec_run = 0x0

        exec_begin = 0x0

        exec_end = 0x0

        param_error = 0x0

        hide_argv = 0

        ini_entries_len = 110

(gdb)


Previous Comments:
------------------------------------------------------------------------
[2010-03-24 02:24:50] j...@php.net

Fail in so many ways.. try http://pecl.php.net/bugs/ and ditch that
suhosin crap first.

------------------------------------------------------------------------
[2010-03-23 20:55:08] daynejordan at gmail dot com

Description:
------------
server2# php -v

PHP 5.2.12 with Suhosin-Patch 0.9.7 (cli) (built: Mar 23 2010 12:15:19)


Copyright (c) 1997-2009 The PHP Group

Zend Engine v2.2.0, Copyright (c) 1998-2009 Zend Technologies

Segmentation fault (core dumped)



(There is no newer port for FreeBSD than 5.2.12)



server2# cat distinfo

MD5 (ffmpeg-php-0.6.0.tbz2) = f779c0dbffda9dac54729d60c0e04c05

SHA256 (ffmpeg-php-0.6.0.tbz2) =
ec8a9847e0f4d5101a5afedb7dac318e9a13f099865215ae99d08d56add9b141

SIZE (ffmpeg-php-0.6.0.tbz2) = 275557

server2# 



I've tried using FreeBSD-6.4, 7.2 and 7.3 - all fresh installs. From the
ports tree install php5-ffmpeg, which installs ffmpeg from ports as
well. No errors during compilation. After installation is complete
simply executing php -v will result in a core dump, doing php -m clearly
shows the module loaded. Tried re-ordering modules in extensions.ini
file as well. Running ffmpeg via cli works fine. If you're using
Apache22 it will restart ok, if using Apache-1.3.x it will fail to
restart - yet leaves no error messages in logs or running thru gdb httpd
-X.





Actual result:
--------------
server2# gdb /usr/local/bin/php php.core

GNU gdb 6.1.1 [FreeBSD]

This GDB was configured as "i386-marcel-freebsd"...(no debugging symbols
found)...

Core was generated by `php'.

Program terminated with signal 11, Segmentation fault.

Reading symbols from /lib/libcrypt.so.4...(no debugging symbols
found)...done.

Loaded symbols for /lib/libcrypt.so.4

Reading symbols from /usr/lib/librt.so.1...(no debugging symbols
found)...done.

Loaded symbols for /usr/lib/librt.so.1

Reading symbols from /lib/libm.so.5...(no debugging symbols
found)...done.

Loaded symbols for /lib/libm.so.5

Reading symbols from /usr/local/lib/libxml2.so.5...(no debugging symbols
found)...done.

Loaded symbols for /usr/local/lib/libxml2.so.5

Reading symbols from /lib/libz.so.4...(no debugging symbols
found)...done.

Loaded symbols for /lib/libz.so.4

Reading symbols from /usr/local/lib/libiconv.so.3...(no debugging
symbols found)...done.

Loaded symbols for /usr/local/lib/libiconv.so.3

Reading symbols from /lib/libc.so.7...(no debugging symbols
found)...done.

Loaded symbols for /lib/libc.so.7

Reading symbols from /libexec/ld-elf.so.1...(no debugging symbols
found)...done.

Loaded symbols for /libexec/ld-elf.so.1

#0  0x29bb2480 in ?? ()

(gdb) bt

#0  0x29bb2480 in ?? ()

#1  0x285c215b in pthread_once () from /lib/libc.so.7

#2  0x28350092 in xmlIsMainThread () from /usr/local/lib/libxml2.so.5

#3  0x2834f647 in __xmlLastError () from /usr/local/lib/libxml2.so.5

#4  0x282db847 in xmlResetLastError () from /usr/local/lib/libxml2.so.5

#5  0x282e282f in xmlCleanupParser () from /usr/local/lib/libxml2.so.5

#6  0x080847eb in php_libxml_shutdown ()

#7  0x0808481b in zm_shutdown_libxml ()

#8  0x0814c04e in module_destructor ()

#9  0x081523b4 in zend_hash_apply_deleter ()

#10 0x081525f8 in zend_hash_graceful_reverse_destroy ()

#11 0x081488ce in zend_shutdown ()

#12 0x0810642f in php_module_shutdown ()

#13 0x081c5a60 in main ()

(gdb)



server2# gdb /usr/local/bin/php

GNU gdb 6.1.1 [FreeBSD]

This GDB was configured as "i386-marcel-freebsd"...

(gdb) run -v

Starting program: /usr/local/bin/php -v

(no debugging symbols found)...[snipped repetitive]

[New Thread 0x286be040 (LWP 100081)]

PHP 5.2.12 with Suhosin-Patch 0.9.7 (cli) (built: Mar 23 2010 12:15:19)


Copyright (c) 1997-2009 The PHP Group

Zend Engine v2.2.0, Copyright (c) 1998-2009 Zend Technologies

[New LWP 100081]

suspend error: generic error

[Switching to LWP 100081]

Stopped due to shared library event

(gdb) Quit



(All other modules removed in extensions.ini except ffmpeg.so)

server2# php -m

[PHP Modules]

date

ffmpeg

libxml

Reflection

standard



[Zend Modules]



Segmentation fault (core dumped)

server2#



server2# ffmpeg -version

FFmpeg version 0.5.1, Copyright (c) 2000-2009 Fabrice Bellard, et al.

  configuration: --prefix=/usr/local --mandir=/usr/local/man
--enable-shared --enable-gpl --enable-swscale --enable-postproc
--enable-avfilter --enable-avfilter-lavf --enable-pthreads
--enable-memalign-hack --cc=cc
--extra-cflags=-I/usr/local/include/vorbis -I/usr/local/include
--extra-ldflags=-L/usr/local/lib  --extra-libs=-pthread --disable-debug
--disable-sse --disable-mmx --disable-libamr-nb --disable-libamr-wb
--disable-libdirac --enable-libfaac --enable-nonfree --enable-libfaad
--enable-libfaadbin --disable-ffserver --disable-libgsm --disable-vhook
--disable-ipv6 --enable-libmp3lame --disable-libopenjpeg
--enable-libschroedinger --disable-ffplay --disable-libspeex
--enable-libtheora --enable-libvorbis --disable-x11grab --enable-libx264
--enable-libxvid

  libavutil     49.15. 0 / 49.15. 0

  libavcodec    52.20. 1 / 52.20. 1

  libavformat   52.31. 0 / 52.31. 0

  libavdevice   52. 1. 0 / 52. 1. 0

  libavfilter    0. 4. 0 /  0. 4. 0

  libswscale     0. 7. 1 /  0. 7. 1

  libpostproc   51. 2. 0 / 51. 2. 0

  built on Mar 23 2010 15:05:42, gcc: 4.2.1 20070719  [FreeBSD]

FFmpeg 0.5.1

libavutil     49.15. 0 / 49.15. 0

libavcodec    52.20. 1 / 52.20. 1

libavformat   52.31. 0 / 52.31. 0

libavdevice   52. 1. 0 / 52. 1. 0

libavfilter    0. 4. 0 /  0. 4. 0

libswscale     0. 7. 1 /  0. 7. 1

libpostproc   51. 2. 0 / 51. 2. 0

server2# 




------------------------------------------------------------------------



-- 
Edit this bug report at http://bugs.php.net/bug.php?id=51372&edit=1

Reply via email to