gmtp crashes when I try to add flac files to my Galaxy Nexus device.
There exists a workaround: Rename files with mp3 extension, add files to device, then change the name of the files that were added to the device back to the flac extension.
Just like to find out a few things, so I might be able to pinpoint the location of the fault.
What version of libmtp is installed?
What version of flac is installed?
Was the file encoded with the flac itself, or some other library that is capable of outputting flac files?
Is it possible to get a copy of the flac file that is failing.
Is it possible to get a stack trace when gmtp crashes?
Within gmtp, it's the same code that uploads all media files (MP3, WMA, FLAC, OGG), so for it to work with one and not the other points to:
There is a bug in libmtp. (unlikely).
There is a bug in Android. (More likely than you would think).
There is a bug in the application that encoded the file, resulting in corrupt headers. (which could cause gmtp to crash due to some internal field calculations).
The file is not using proper flac metadata. (which could cause gmtp to crash due to some internal field calculations).
There is a bug in libflac. (that is causing bad readings from the file ion getting the metadata).
--
Regards,
Darran
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
The Gentoo version of libmtp is 1.1.3- I am not sure that this is actual libmtp version. The shared library is /usr/lib64/libmtp.so.9.0.3
The Gentoo version of flac is 1.2.1-r3. This seems to be the actual flac version sincd flac -v returns "flac 1.2.1".
The flac was created with KAudioCreator (a KDE application). I am not sure if this program uses /usr/bin/flac. I will try to create a file using /usr/bin/flac and test whether the problem persists.
I tried to attach a flac file, but it looks like the filesize was too big and the web browser froze. I will try again in a separate reply to upload a smaller file. (difficult to further reduce the size of flac files)
The stack trace of the core dump may not be all that useful since the debug symbols are missing. It will take me a while to figure out how to recompile all the relevant modules with the debug information. Anyway, here is the stack trace without the debug information:<P/>
. $ gdb /usr/bin/gmtp --core core
GNU gdb (Gentoo 7.3.1 p2) 7.3.1
Copyright (C) 2011 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law. Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-pc-linux-gnu".
For bug reporting instructions, please see:
<http://bugs.gentoo.org/>...
Reading symbols from /usr/bin/gmtp...(no debugging symbols found)...done.
[New LWP 6242]
[New LWP 6267]
[New LWP 6243]
warning: Can't read pathname for load map: Input/output error.
[Thread debugging using libthread_db enabled]
Core was generated by `gmtp'.
Program terminated with signal 11, Segmentation fault.
#0 0x00007f9d2180be59 in free () from /lib64/libc.so.6
(gdb) where
#0 0x00007f9d2180be59 in free () from /lib64/libc.so.6
#1 0x00000000004218dd in ?? ()
#2 0x000000000040d26b in ?? ()
#3 0x00007f9d226451d7 in g_slist_foreach () from /usr/lib64/libglib-2.0.so.0
#4 0x000000000041cc1f in ?? ()
#5 0x00007f9d22b175d4 in g_closure_invoke () from /usr/lib64/libgobject-2.0.so.0
#6 0x00007f9d22b296a2 in ?? () from /usr/lib64/libgobject-2.0.so.0
#7 0x00007f9d22b3288c in g_signal_emit_valist () from /usr/lib64/libgobject-2.0.so.0
#8 0x00007f9d22b32be2 in g_signal_emit_by_name () from /usr/lib64/libgobject-2.0.so.0
#9 0x00007f9d22b175d4 in g_closure_invoke () from /usr/lib64/libgobject-2.0.so.0
#10 0x00007f9d22b296a2 in ?? () from /usr/lib64/libgobject-2.0.so.0
#11 0x00007f9d22b3288c in g_signal_emit_valist () from /usr/lib64/libgobject-2.0.so.0
#12 0x00007f9d22b32a23 in g_signal_emit () from /usr/lib64/libgobject-2.0.so.0
#13 0x00007f9d23355ebd in ?? () from /usr/lib64/libgtk-3.so.0
#14 0x00007f9d22b175d4 in g_closure_invoke () from /usr/lib64/libgobject-2.0.so.0
#15 0x00007f9d22b28ed9 in ?? () from /usr/lib64/libgobject-2.0.so.0
#16 0x00007f9d22b3288c in g_signal_emit_valist () from /usr/lib64/libgobject-2.0.so.0
#17 0x00007f9d22b32a23 in g_signal_emit () from /usr/lib64/libgobject-2.0.so.0
#18 0x00007f9d23354ddd in ?? () from /usr/lib64/libgtk-3.so.0
#19 0x00007f9d23411ab8 in ?? () from /usr/lib64/libgtk-3.so.0
#20 0x00007f9d22b175d4 in g_closure_invoke () from /usr/lib64/libgobject-2.0.so.0
#21 0x00007f9d22b294e0 in ?? () from /usr/lib64/libgobject-2.0.so.0
#22 0x00007f9d22b32661 in g_signal_emit_valist () from /usr/lib64/libgobject-2.0.so.0
#23 0x00007f9d22b32a23 in g_signal_emit () from /usr/lib64/libgobject-2.0.so.0
#24 0x00007f9d23539d3f in ?? () from /usr/lib64/libgtk-3.so.0
#25 0x00007f9d2341123a in gtk_propagate_event () from /usr/lib64/libgtk-3.so.0
#26 0x00007f9d2341166b in gtk_main_do_event () from /usr/lib64/libgtk-3.so.0
#27 0x00007f9d2155d222 in ?? () from /usr/lib64/libgdk-3.so.0
#28 0x00007f9d22626e52 in g_main_context_dispatch () from /usr/lib64/libglib-2.0.so.0
#29 0x00007f9d22627630 in ?? () from /usr/lib64/libglib-2.0.so.0
#30 0x00007f9d22627b7a in g_main_loop_run () from /usr/lib64/libglib-2.0.so.0
#31 0x00007f9d23410a6d in gtk_main () from /usr/lib64/libgtk-3.so.0
#32 0x000000000040af99 in ?? ()
#33 0x00007f9d217b42ad in __libc_start_main () from /lib64/libc.so.6
#34 0x000000000040ab39 in ?? ()
#35 0x00007fff755d6ed8 in ?? ()
#36 0x000000000000001c in ?? ()
#37 0x0000000000000001 in ?? ()
#38 0x00007fff755d8b9f in ?? ()
#39 0x0000000000000000 in ?? ()
(gdb)
Thank you for your help, Martin
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Unfortunately a quick test with the same versions of software/libraries doesn't expose the issue you are seeing on my system. I'll try to get hold of another Linux box and another android device (all my tests devices are not android based, and all typically implement MTP extremely well), and test again.
Another question, does it crash before it sends, during sending, or when the transfer is complete?
Also to get a better stack trace, you can enable '-g' in CLFAGS in the Makefile, and rebuild gmtp, to test again. Also can you ensure all optimisations are disabled (remove all -O flags from CFLAGS in the Makefile). The stack trace you posted would indicate a double free() bug, but can't locate it.
--
Regards
Darran
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
My apologies for taking so long but I find time for this only on the weekend and I ran into another problem. Apparently, the linker stripped the debug information after I compiled it in. Anyway, I finally got this resolved and here is the latest stack trace. I recompiled gmtp, glib, and gtk+ and the question marks are now all gone. Unfortunately, I forgot removing the -O2 flag. If this turns out to be a stumbling block, let me know and I will redo one more time. Also, gdb still shows a warning "can't read pathname for load map". I don't know what this means and whether it matters.
$ gdb /usr/bin/gmtp core
GNU gdb (Gentoo 7.3.1 p2) 7.3.1
Copyright (C) 2011 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law. Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-pc-linux-gnu".
For bug reporting instructions, please see:
<http://bugs.gentoo.org/>...
Reading symbols from /usr/bin/gmtp...Reading symbols from /usr/lib64/debug/usr/bin/gmtp.debug...done.
done.
[New LWP 26660]
[New LWP 26661]
[New LWP 26671]
warning: Can't read pathname for load map: Input/output error.
[Thread debugging using libthread_db enabled]
Core was generated by `gmtp'.
Program terminated with signal 11, Segmentation fault.
#0 0x00007f07abab0e59 in free () from /lib64/libc.so.6
(gdb) where
#0 0x00007f07abab0e59 in free () from /lib64/libc.so.6
#1 0x00000000004218dd in get_flac_tags (
filename=0x11fe950 "/mnt/data/music/Folk/Givers/InLight/08 - Atlantic.flac",
trackinformation=0x11d6bf0) at src/metatag_info.c:520
#2 0x000000000040d26b in filesAdd (
filename=0x11fe950 "/mnt/data/music/Folk/Givers/InLight/08 - Atlantic.flac") at src/mtp.c:629
#3 0x00007f07ac8ea1d7 in g_slist_foreach (list=<optimized out>, func=0x414bc0 <__filesAdd>,
user_data=0x0) at gslist.c:880
#4 0x000000000041cc1f in on_filesAdd_activate (menuitem=<optimized out>, user_data=<optimized out>)
at src/callbacks.c:160
#5 0x00007f07acdbc5d4 in g_closure_invoke (closure=0xee8ec0, return_value=0x0, n_param_values=1,
param_values=0x11336a0, invocation_hint=<optimized out>) at gclosure.c:774
#6 0x00007f07acdce6a2 in signal_emit_unlocked_R (node=<optimized out>, detail=0,
instance=0xecad20, emission_return=0x0, instance_and_params=0x11336a0) at gsignal.c:3272
#7 0x00007f07acdd788c in g_signal_emit_valist (instance=<optimized out>,
signal_id=<optimized out>, detail=<optimized out>, var_args=<optimized out>) at gsignal.c:3003
#8 0x00007f07acdd7be2 in g_signal_emit_by_name (instance=<optimized out>,
detailed_signal=0x7f07ad856487 "clicked") at gsignal.c:3097
#9 0x00007f07acdbc5d4 in g_closure_invoke (closure=0xee58a0, return_value=0x0, n_param_values=1,
param_values=0x1130ce0, invocation_hint=<optimized out>) at gclosure.c:774
#10 0x00007f07acdce6a2 in signal_emit_unlocked_R (node=<optimized out>, detail=0,
instance=0xe9de40, emission_return=0x0, instance_and_params=0x1130ce0) at gsignal.c:3272
#11 0x00007f07acdd788c in g_signal_emit_valist (instance=<optimized out>,
signal_id=<optimized out>, detail=<optimized out>, var_args=<optimized out>) at gsignal.c:3003
#12 0x00007f07acdd7a23 in g_signal_emit (instance=<optimized out>, signal_id=<optimized out>,
detail=<optimized out>) at gsignal.c:3060
#13 0x00007f07ad5faecd in gtk_real_button_released (button=0xe9de40) at gtkbutton.c:1826
#14 0x00007f07acdbc5d4 in g_closure_invoke (closure=0xed8390, return_value=0x0, n_param_values=1,
param_values=0x1127d60, invocation_hint=<optimized out>) at gclosure.c:774
#15 0x00007f07acdcded9 in signal_emit_unlocked_R (node=<optimized out>, detail=0,
instance=0xe9de40, emission_return=0x0, instance_and_params=0x1127d60) at gsignal.c:3202
#16 0x00007f07acdd788c in g_signal_emit_valist (instance=<optimized out>,
signal_id=<optimized out>, detail=<optimized out>, var_args=<optimized out>) at gsignal.c:3003
#17 0x00007f07acdd7a23 in g_signal_emit (instance=<optimized out>, signal_id=<optimized out>,
detail=<optimized out>) at gsignal.c:3060
#18 0x00007f07ad5f9ded in gtk_button_button_release (widget=<optimized out>, event=<optimized out>)
at gtkbutton.c:1718
#19 0x00007f07ad6b6ac8 in _gtk_marshal_BOOLEAN__BOXED (closure=0xdffe70,
return_value=0x7fff4a199590, n_param_values=<optimized out>, param_values=0x1115e40,
invocation_hint=<optimized out>, marshal_data=<optimized out>) at gtkmarshalers.c:85
#20 0x00007f07acdbc5d4 in g_closure_invoke (closure=0xdffe70, return_value=0x7fff4a199590,
n_param_values=2, param_values=0x1115e40, invocation_hint=<optimized out>) at gclosure.c:774
#21 0x00007f07acdce4e0 in signal_emit_unlocked_R (node=<optimized out>, detail=0,
instance=0xe9de40, emission_return=0x7fff4a199700, instance_and_params=0x1115e40)
---Type <return> to continue, or q <return> to quit---
at gsignal.c:3310
#22 0x00007f07acdd7661 in g_signal_emit_valist (instance=<optimized out>,
signal_id=<optimized out>, detail=<optimized out>, var_args=<optimized out>) at gsignal.c:3013
#23 0x00007f07acdd7a23 in g_signal_emit (instance=<optimized out>, signal_id=<optimized out>,
detail=<optimized out>) at gsignal.c:3060
#24 0x00007f07ad7ded4f in gtk_widget_event_internal (widget=0xe9de40, event=0xfcf330)
at gtkwidget.c:6132
#25 0x00007f07ad6b624a in gtk_propagate_event (widget=0xe9de40, event=0xfcf330) at gtkmain.c:2614
#26 0x00007f07ad6b667b in gtk_main_do_event (event=0xfcf330) at gtkmain.c:1889
#27 0x00007f07ab802242 in gdk_event_source_dispatch (source=<optimized out>,
callback=<optimized out>, user_data=<optimized out>) at gdkeventsource.c:360
#28 0x00007f07ac8cbe52 in g_main_dispatch (context=0xe389e0) at gmain.c:2441
#29 g_main_context_dispatch (context=0xe389e0) at gmain.c:3011
#30 0x00007f07ac8cc630 in g_main_context_iterate (context=0xe389e0, block=1, dispatch=1,
self=<optimized out>) at gmain.c:3089
#31 0x00007f07ac8ccb7a in g_main_loop_run (loop=0x106a300) at gmain.c:3297
#32 0x00007f07ad6b5a7d in gtk_main () at gtkmain.c:1362
#33 0x000000000040af99 in main (argc=1, argv=0x7fff4a199b58) at src/main.c:134
(gdb)
I don't know when exactly the crash occurs. However, I am pretty sure that it is not after the send because the file does not get transferred the the device.
Thank you for your patience, Martin
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Actually, I was curious about the impact of the -O2 flag. Thus, I removed it and recompiled. Here is the stack trace without this flag
$ gdb /usr/bin/gmtp core
GNU gdb (Gentoo 7.3.1 p2) 7.3.1
Copyright (C) 2011 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law. Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-pc-linux-gnu".
For bug reporting instructions, please see:
<http://bugs.gentoo.org/>...
Reading symbols from /usr/bin/gmtp...Reading symbols from /usr/lib64/debug/usr/bin/gmtp.debug...done.
done.
[New LWP 18012]
[New LWP 18013]
[New LWP 18022]
warning: Can't read pathname for load map: Input/output error.
[Thread debugging using libthread_db enabled]
Core was generated by `gmtp'.
Program terminated with signal 6, Aborted.
#0 0x00007f8545c4a655 in raise () from /lib64/libc.so.6
(gdb) where
#0 0x00007f8545c4a655 in raise () from /lib64/libc.so.6
#1 0x00007f8545c4b8fa in abort () from /lib64/libc.so.6
#2 0x00007f8545c84d24 in ?? () from /lib64/libc.so.6
#3 0x00007f8545c8a0f5 in ?? () from /lib64/libc.so.6
#4 0x00007f8545c8ee8c in free () from /lib64/libc.so.6
#5 0x0000000000427a9d in get_flac_tags (
filename=0x10e6120 "/mnt/data/music/Folk/Givers/InLight/08 - Atlantic.flac",
trackinformation=0x111ffa0) at src/metatag_info.c:520
#6 0x000000000040c22a in filesAdd (
filename=0x10e6120 "/mnt/data/music/Folk/Givers/InLight/08 - Atlantic.flac") at src/mtp.c:629
#7 0x000000000041644b in __filesAdd (
filename=0x10e6120 "/mnt/data/music/Folk/Givers/InLight/08 - Atlantic.flac")
at src/interface.c:2216
#8 0x00007f8546ad7bb0 in g_slist_foreach (list=0x7f852c00d4c0, func=0x416389 <__filesAdd>,
user_data=0x0) at gslist.c:880
#9 0x0000000000421b6e in on_filesAdd_activate (menuitem=0xe8cd20, user_data=0x0)
at src/callbacks.c:160
#10 0x00007f8546fc48a4 in g_cclosure_marshal_VOID__VOID (closure=0xebcf90, return_value=0x0,
n_param_values=1, param_values=0x10dc880, invocation_hint=0x7fffb4b652a0, marshal_data=0x0)
at gmarshal.c:85
#11 0x00007f8546fc2ba0 in g_closure_invoke (closure=0xebcf90, return_value=0x0, n_param_values=1,
param_values=0x10dc880, invocation_hint=0x7fffb4b652a0) at gclosure.c:774
---Type <return> to continue, or q <return> to quit---
#12 0x00007f8546fdd736 in signal_emit_unlocked_R (node=0xe9a880, detail=0, instance=0xe8cd20,
emission_return=0x0, instance_and_params=0x10dc880) at gsignal.c:3272
#13 0x00007f8546fdc6af in g_signal_emit_valist (instance=0xe8cd20, signal_id=161, detail=0,
var_args=0x7fffb4b65530) at gsignal.c:3003
#14 0x00007f8546fdce56 in g_signal_emit_by_name (instance=0xe8cd20,
detailed_signal=0x7f8547c2551f "clicked") at gsignal.c:3097
#15 0x00007f8547a75d57 in button_clicked (widget=0xe5fe40, button=0xe8cd20) at gtktoolbutton.c:813
#16 0x00007f8546fc48a4 in g_cclosure_marshal_VOID__VOID (closure=0xea9910, return_value=0x0,
n_param_values=1, param_values=0x10db780, invocation_hint=0x7fffb4b657f0, marshal_data=0x0)
at gmarshal.c:85
#17 0x00007f8546fc2ba0 in g_closure_invoke (closure=0xea9910, return_value=0x0, n_param_values=1,
param_values=0x10db780, invocation_hint=0x7fffb4b657f0) at gclosure.c:774
#18 0x00007f8546fdd736 in signal_emit_unlocked_R (node=0xe98430, detail=0, instance=0xe5fe40,
emission_return=0x0, instance_and_params=0x10db780) at gsignal.c:3272
#19 0x00007f8546fdc6af in g_signal_emit_valist (instance=0xe5fe40, signal_id=154, detail=0,
var_args=0x7fffb4b65a80) at gsignal.c:3003
#20 0x00007f8546fdcc48 in g_signal_emit (instance=0xe5fe40, signal_id=154, detail=0)
at gsignal.c:3060
#21 0x00007f854784eb09 in gtk_button_clicked (button=0xe5fe40) at gtkbutton.c:1197
#22 0x00007f854784fef7 in gtk_real_button_released (button=0xe5fe40) at gtkbutton.c:1826
#23 0x00007f8546fc48a4 in g_cclosure_marshal_VOID__VOID (closure=0xe9a390, return_value=0x0,
n_param_values=1, param_values=0x10db700, invocation_hint=0x7fffb4b65df0,
marshal_data=0x7f854784fe9c) at gmarshal.c:85
#24 0x00007f8546fc2ed4 in g_type_class_meta_marshal (closure=0xe9a390, return_value=0x0,
n_param_values=1, param_values=0x10db700, invocation_hint=0x7fffb4b65df0, marshal_data=0x3f8)
at gclosure.c:885
#25 0x00007f8546fc2ba0 in g_closure_invoke (closure=0xe9a390, return_value=0x0, n_param_values=1,
param_values=0x10db700, invocation_hint=0x7fffb4b65df0) at gclosure.c:774
#26 0x00007f8546fdd341 in signal_emit_unlocked_R (node=0xe9a490, detail=0, instance=0xe5fe40,
emission_return=0x0, instance_and_params=0x10db700) at gsignal.c:3202
#27 0x00007f8546fdc6af in g_signal_emit_valist (instance=0xe5fe40, signal_id=153, detail=0,
var_args=0x7fffb4b66080) at gsignal.c:3003
#28 0x00007f8546fdcc48 in g_signal_emit (instance=0xe5fe40, signal_id=153, detail=0)
at gsignal.c:3060
#29 0x00007f854784ea5e in gtk_button_released (button=0xe5fe40) at gtkbutton.c:1183
#30 0x00007f854784fc4d in gtk_button_button_release (widget=0xe5fe40, event=0x1098090)
at gtkbutton.c:1718
#31 0x00007f854794f308 in _gtk_marshal_BOOLEAN__BOXED (closure=0xdc1e70,
return_value=0x7fffb4b663d0, n_param_values=2, param_values=0x10ccc40,
invocation_hint=0x7fffb4b66400, marshal_data=0x7f854784fc1d) at gtkmarshalers.c:85
#32 0x00007f8546fc2ed4 in g_type_class_meta_marshal (closure=0xdc1e70, return_value=0x7fffb4b663d0,
n_param_values=2, param_values=0x10ccc40, invocation_hint=0x7fffb4b66400, marshal_data=0x188)
at gclosure.c:885
#33 0x00007f8546fc2ba0 in g_closure_invoke (closure=0xdc1e70, return_value=0x7fffb4b663d0,
n_param_values=2, param_values=0x10ccc40, invocation_hint=0x7fffb4b66400) at gclosure.c:774
#34 0x00007f8546fdd933 in signal_emit_unlocked_R (node=0xdc1ee0, detail=0, instance=0xe5fe40,
emission_return=0x7fffb4b66580, instance_and_params=0x10ccc40) at gsignal.c:3310
#35 0x00007f8546fdc73e in g_signal_emit_valist (instance=0xe5fe40, signal_id=29, detail=0,
var_args=0x7fffb4b66690) at gsignal.c:3013
#36 0x00007f8546fdcc48 in g_signal_emit (instance=0xe5fe40, signal_id=29, detail=0)
at gsignal.c:3060
#37 0x00007f8547ae75da in gtk_widget_event_internal (widget=0xe5fe40, event=0x1098090)
at gtkwidget.c:6132
#38 0x00007f8547ae6e52 in gtk_widget_event (widget=0xe5fe40, event=0x1098090) at gtkwidget.c:5848
#39 0x00007f854794f0c2 in gtk_propagate_event (widget=0xe5fe40, event=0x1098090) at gtkmain.c:2614
#40 0x00007f854794de3c in gtk_main_do_event (event=0x1098090) at gtkmain.c:1889
#41 0x00007f85459a423e in _gdk_event_emit (event=0x1098090) at gdkevents.c:71
#42 0x00007f85459d8284 in gdk_event_source_dispatch (source=0xdfc870, callback=0, user_data=0x0)
at gdkeventsource.c:360
#43 0x00007f8546ab2118 in g_main_dispatch (context=0xdfa9e0) at gmain.c:2441
#44 0x00007f8546ab3659 in g_main_context_dispatch (context=0xdfa9e0) at gmain.c:3011
#45 0x00007f8546ab3b0f in g_main_context_iterate (context=0xdfa9e0, block=1, dispatch=1,
self=0xda80b0) at gmain.c:3089
#46 0x00007f8546ab426a in g_main_loop_run (loop=0x102b240) at gmain.c:3297
#47 0x00007f854794d3e7 in gtk_main () at gtkmain.c:1362
#48 0x000000000040acd0 in main (argc=1, argv=0x7fffb4b66c18) at src/main.c:134
(gdb) src/metatag_info
Martin
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Thank you for the stack trace, as it pointed to where the sigfault was happening. (This was a strange one, as the bug only showed up on Gentoo based systems, and not any other Linux based system I tried)?
I've uploaded a fix into CVS, so if you could download the CVS version and try that one, it would be greatly appreciated.
Normal 'make' routine to build.
However there is no need to reinstall it. just run:
$./gmtp --datapath /usr/bin
in the root of the download and you can test it that way without reinstalling. (Be aware the default installation path is /usr/local/ ).
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I downloaded the new version from Gentoo and it works. I never got a chance to test the CVS version because I was traveling the last couple of weeks and had not access to my linux box. Thank you for fixing the problem, Martin
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
gmtp crashes when I try to add flac files to my Galaxy Nexus device.
There exists a workaround: Rename files with mp3 extension, add files to device, then change the name of the files that were added to the device back to the flac extension.
Linux distro: Gentoo
Keranel version: 3.2.12
gmtp (Gentoo) version: 3.1.3-r300
Androdid version: 4.0.4 (Ice Cream Sandwich, Google's Factory Image "yakju" build)
Hi Martin,
Thanks for the information.
Just like to find out a few things, so I might be able to pinpoint the location of the fault.
Within gmtp, it's the same code that uploads all media files (MP3, WMA, FLAC, OGG), so for it to work with one and not the other points to:
--
Regards,
Darran
Hi Darran:
Thank you for your help, Martin
Hi Martin,
Thank you for the stack trace and the flac file.
Unfortunately a quick test with the same versions of software/libraries doesn't expose the issue you are seeing on my system. I'll try to get hold of another Linux box and another android device (all my tests devices are not android based, and all typically implement MTP extremely well), and test again.
Another question, does it crash before it sends, during sending, or when the transfer is complete?
Also to get a better stack trace, you can enable '-g' in CLFAGS in the Makefile, and rebuild gmtp, to test again. Also can you ensure all optimisations are disabled (remove all -O flags from CFLAGS in the Makefile). The stack trace you posted would indicate a double free() bug, but can't locate it.
--
Regards
Darran
Here is a relatively small flac file that crashes gmtp.
Darran:
My apologies for taking so long but I find time for this only on the weekend and I ran into another problem. Apparently, the linker stripped the debug information after I compiled it in. Anyway, I finally got this resolved and here is the latest stack trace. I recompiled gmtp, glib, and gtk+ and the question marks are now all gone. Unfortunately, I forgot removing the -O2 flag. If this turns out to be a stumbling block, let me know and I will redo one more time. Also, gdb still shows a warning "can't read pathname for load map". I don't know what this means and whether it matters.
I don't know when exactly the crash occurs. However, I am pretty sure that it is not after the send because the file does not get transferred the the device.
Thank you for your patience, Martin
Darran:
Actually, I was curious about the impact of the -O2 flag. Thus, I removed it and recompiled. Here is the stack trace without this flag
Martin
Hi Martin,
Thank you for the stack trace, as it pointed to where the sigfault was happening. (This was a strange one, as the bug only showed up on Gentoo based systems, and not any other Linux based system I tried)?
I've uploaded a fix into CVS, so if you could download the CVS version and try that one, it would be greatly appreciated.
CVS Access: $ cvs -z3 -d:pserver:anonymous@gmtp.cvs.sourceforge.net:/cvsroot/gmtp checkout -P Hellfire/gMTP
Normal 'make' routine to build.
However there is no need to reinstall it. just run:
$./gmtp --datapath /usr/bin
in the root of the download and you can test it that way without reinstalling. (Be aware the default installation path is /usr/local/ ).
I downloaded the new version from Gentoo and it works. I never got a chance to test the CVS version because I was traveling the last couple of weeks and had not access to my linux box. Thank you for fixing the problem, Martin