Re: [PATCH] device: increase object ref count before invoking g_idle_add

2016-05-05 Thread Thomas Haller
On Wed, 2016-05-04 at 17:27 +0800, Shih-Yuan Lee (FourDollars) wrote: > --- >  src/devices/nm-device.c | 25 + >  1 file changed, 17 insertions(+), 8 deletions(-) > > diff --git a/src/devices/nm-device.c b/src/devices/nm-device.c > index ad6f835..77f8874 100644 > ---

[PATCH] device: increase object ref count before invoking g_idle_add

2016-05-04 Thread Shih-Yuan Lee (FourDollars)
--- src/devices/nm-device.c | 25 + 1 file changed, 17 insertions(+), 8 deletions(-) diff --git a/src/devices/nm-device.c b/src/devices/nm-device.c index ad6f835..77f8874 100644 --- a/src/devices/nm-device.c +++ b/src/devices/nm-device.c @@ -1990,8 +1990,8 @@

[PATCH] device: increase object ref count before invoking g_idle_add

2016-05-04 Thread Shih-Yuan Lee (FourDollars)
There are three different crash cases during the suspend stress test. Inreasing the object reference count before invoking g_idle_add() can avoid this kind of race condition. === crash #1 === GNU gdb (Ubuntu 7.11-0ubuntu1) 7.11 Copyright (C) 2016 Free Software Foundation, Inc. License GPLv3+: