arturoc / gstreamer1.0-rs

Idiomatic bindings for Gstreamer on Rust.
MIT License
36 stars 14 forks source link

segfault armhf #22

Closed grafoo closed 7 years ago

grafoo commented 7 years ago

hi! i compiled the example from https://github.com/arturoc/gstreamer1.0-rs/blob/master/examples/playbin.rs for armv7-unknown-linux-gnueabihf but unfortionally it segfaults when e.g. using it like ./playbin http://www.podtrac.com/pts/redirect.mp3/traffic.libsyn.com/jnite/bsd-0166.mp3

can this be related to the gst_init in https://github.com/arturoc/gstreamer1.0-rs/commit/7a435054aafac1335a7f6761ea92262a43658fcf ? i also tried your new approach with c_char but that didn't work either.

here is the processor information just for completeness:

processor       : 0
model name      : ARMv7 Processor rev 4 (v7l)
BogoMIPS        : 48.00
Features        : swp half thumb fastmult vfp edsp thumbee neon vfpv3 tls vfpv4 idiva idivt vfpd32 lpae evtstrm
CPU implementer : 0x41
CPU architecture: 7
CPU variant     : 0x0
CPU part        : 0xc07
CPU revision    : 4

processor       : 1
model name      : ARMv7 Processor rev 4 (v7l)
BogoMIPS        : 48.00
Features        : swp half thumb fastmult vfp edsp thumbee neon vfpv3 tls vfpv4 idiva idivt vfpd32 lpae evtstrm
CPU implementer : 0x41
CPU architecture: 7
CPU variant     : 0x0
CPU part        : 0xc07
CPU revision    : 4

Hardware        : Allwinner sun7i (A20) Family
Revision        : 0000
Serial          : 0000000000000000

cheers, grafoo

arturoc commented 7 years ago

there could be a bug in that example, usually loading resources from the web is more complex than loading local resources. can you try to load something locally and see if that crashes too? also can you debug the application and post the stack trace?

thanks!

grafoo commented 7 years ago

sorry for the delay :D

but finally:

0x7f585c74 in gst::message::{{impl}}::src_name (self=0xbefff884)
  at /.cargo/registry/src/github.com-1ecc6299db9ec823/gstreamer-0.7.0/src/message.rs:317
317 /.cargo/registry/src/github.com-1ecc6299db9ec823/gstreamer-0.7.0/src/message.rs: No such file or directory.
barmand commented 7 years ago

Hi,

same problem on x86 (32 bits). The main problem is that the Message parse function (src/message.rs) matches always the default case (unknown message).

I suppose that one of the field of the Struct__GstMessage is defined with a type that does not match the actual C type used by gstreamer on 32 bits platforms.

Regards.