obexftp hangs when sending file to Sony Ericsson z520 over usb cable

Bug #41964 reported by Simon Ruggier
12
Affects Status Importance Assigned to Milestone
obexftp (Ubuntu)
Fix Released
Medium
Unassigned

Bug Description

Whenever I've tried to send files to my phone, it would hang at the 'Sending "<file>".../' line, so I tracked down the issue and wrote a patch for it.

It looks like one could consider this a workaround for fixing the relevant driver itself ( I haven't bothered to figure this out), but my patch just adds a retry loop to the function that writes data to the cable driver, which was failing because the write() call was only writing part of what was requested. Should be completely safe from infinite looping, but if I'm wrong (say write
perpetually returns 0, if that's even possible), the results are not catastrophic by any means, because there's a usleep(1) call in the loop as part
of the workaround. So in short, applying this patch can only be good, and may perhaps fix issues with more than just my specific model of phone. It applies cleanly to obexftp-0.18 and obex-ftp0.19, but I would guess that it can be manually applied to 0.10 if desired. I'm submitting it here because I use Ubuntu and would like to improve it.

Revision history for this message
Simon Ruggier (simon80) wrote : obexftp-cablewriteretry.patch

The patch in question

Simon Ruggier (simon80)
description: updated
Revision history for this message
Simon Ruggier (simon80) wrote :

if you're not going to ship the latest version of obexftp (my patch made it into 0.20, I believe) in Edgy, please consider applying this patch to 0.19. I tested the current edgy obexftp on my Dapper install (by adding an edgy deb-src to my sources.list ) and it still doesn't work with my phone. I then added the patch that can be found at http://bugs.gentoo.org/attachment.cgi?id=85776, which is an ever so slightly reworked version of my patch, and with that, obexftp works. It applies cleanly to the latest edgy source package, which is 0.19-5 as of now, if I'm not mistaken.

Revision history for this message
Barry deFreese (bddebian) wrote :

It looks like a similar patch was added to the 0.19-7 package in Debian and thus to Feisty. Is there any chance you could test this? I don't have the equipment to test unfortunately. Thanks.

Changed in obexftp:
status: Unconfirmed → Needs Info
Revision history for this message
Simon Ruggier (simon80) wrote : Re: [Bug 41964] Re: obexftp hangs when sending file to Sony Ericsson z520 over usb cable

I backported 0.19-7 from feisty, and it works, so I guess this will be
fixed in feisty.

Revision history for this message
Barry deFreese (bddebian) wrote :

I am closing this as Fixed in Feisty. If you really want to see this fixed in Edgy, please file a backport request. Thanks for your quick reply!

Changed in obexftp:
status: Needs Info → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.