diff options
author | Dan Winship <danw@redhat.com> | 2015-01-22 13:59:17 -0500 |
---|---|---|
committer | Dan Winship <danw@redhat.com> | 2015-01-23 10:05:20 -0500 |
commit | f0e74622ccfad2eb2193f085b385e4a52ca83026 (patch) | |
tree | 9d4ee50abea113dba85d5a0eca0841446c3b9e5d /vapi | |
parent | 44e065359e4084bd823baf98548c16d35abb6f4f (diff) |
team: fix teamd startup code (rh #1184923)
Since 03a5a85d, NMDeviceTeam was trying to use priv->teamd_pid to
decide whether a teamd_dbus_vanished() call indicated "teamd hasn't
been started yet" or "teamd was previously started and has now
exited". But this resulted in a race condition, where at startup, a
device could call g_dbus_watch_name(), then launch teamd (causing
teamd_pid to get set), and then have gdbus report that teamd hasn't
been started yet before the newly-launched teamd managed to grab the
bus name. Since teamd_pid would already be set when
teamd_dbus_vanished() was called, it would decide that this meant
"teamd was previously started and has now exited", so it would call
teamd_cleanup(), killing the just-started teamd process.
Fix this by having teamd_dbus_vanished() check priv->tdc instead,
which doesn't get set until after the first teamd_dbus_appeared()
call.
Diffstat (limited to 'vapi')
0 files changed, 0 insertions, 0 deletions