obexpushd and obexftp not correctly restarted after S3/S4

Bug #369522 reported by Bill Filler
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
gnome-user-share
Expired
Medium
gnome-user-share (Ubuntu)
Triaged
Low
Unassigned

Bug Description

Binary package hint: gnome-user-share

On Jaunty, package gnome-user-share_2.25.92-0ubuntu2

There appears to be a race condition on suspend/resume and hibernate/thaw which causes obexpushd and obexftp to not get correctly shutdown on suspend/hibernate and it attempts to restart them on resume, which fails. This makes any subsequent attempt to transfer files to the system via bluetooth fail.

I've traced this to src/user-share.c consolekit_init() method and sessionchanged_cb(). When the condition fails, sessionchanged_cb gets an "Active" on suspend/hibernate rather than "Inactive" which causes the services to not get stopped. It gets another "Active" on resume/thaw and then all hell breaks loose.

I've attached a patch which simplifies the dbus code to register a callback which is passed the active/inactive state, thus eliminating the race condition. This same method is used in netbook-launcher.

Revision history for this message
Bill Filler (bfiller) wrote :
Revision history for this message
Baptiste Mille-Mathias (bmillemathias) wrote :

Thanks Bill, I've formarwed your patch upstream, next time ping any people to have your patch reviewed.

Thanks

Revision history for this message
Baptiste Mille-Mathias (bmillemathias) wrote :

Bill,

the upstream author asks for reproducing steps, it is possble to provide them here or in the upstream bug?

Thanks

Revision history for this message
Bill Filler (bfiller) wrote :

Added comment in upstream bug report on steps to reproduce. This bug was filed originally filed almost 1 year ago, so I have not verified if still exists with the latest code.

Changed in gnome-user-share:
status: Unknown → New
Changed in gnome-user-share (Ubuntu):
importance: Undecided → Low
status: New → Triaged
Changed in gnome-user-share:
importance: Unknown → Medium
Changed in gnome-user-share:
status: New → Expired
Revision history for this message
yuanzhanghui (yuanzhanghui-1988) wrote :

Can somebody tell me why ubuntu PC (12.04 ) can't automatically receive files over Bluetooth and save them with no user interaction ?
I already install obexpushd with the command : $sudo apt-get install obexpushd
After installed it , i create a file : /etc/init/obexpushd.conf and add the following code in this file .
chdir /home/USERNAME
exec obexpushd -n
start on startup
$sudo initctl reload-configuration
$sudo start obexpushd
But it seems can't automatically receive files over Bluetooth .

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.