Re: [Patch] Fix a crash in vpn starters



On Sat, 2006-10-28 at 11:54 +0300, Tambet Ingo wrote:
> Hey,
> 
> Attached is a patch to fix a race condition when starting vpn sessions
> and something goes wrong early on. Instead of returning an error
> message, the vpn helpers emit a dbus signal, which might (and sometimes
> does, as described at
> https://bugzilla.novell.com/show_bug.cgi?id=214950) arrive to NM before
> the reply to the startConnection() call. When the reply finally does
> arrive, stuff is already freed and in inconsistent state and bad things
> happen (again, as described at that bugzilla link).
> 
> I'd like to apply the patch to both branches. Additionally, for HEAD.
> I'd also remove all mentions of unused VPN signals which this patch
> removes (stable API jadda-jadda in 0.6).

Looks good, feel free to apply to head and stable.

A lot of the VPN service code is crap, because it was written while DBus
was still somewhat immature, and because there is not yet any dbus
service activation on the system bus.  Ideally, and in the future, we
would not bother exec-ing the vpn service daemons, but simply call the
'startConnection' method and let dbus do the work for us.  Also, the use
of signals is iffy here, as you've rightfully found, and replacing the
use of signalling in the vpn service daemons with reply messages is a
good idea.  Maybe we shouldn't be sending the IP4Config signal, but
instead expect the ip4 config information in the reply message that
comes back from startConnection.

Suggestions appreciated since we should get this right for 0.7 and not
worry about old baggage.

Thanks!
Dan

> Tambet
> _______________________________________________
> NetworkManager-list mailing list
> NetworkManager-list gnome org
> http://mail.gnome.org/mailman/listinfo/networkmanager-list




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]