NetBSD Problem Report #53397

From martin@aprisoft.de  Mon Jun 25 07:00:20 2018
Return-Path: <martin@aprisoft.de>
Received: from mail.netbsd.org (mail.netbsd.org [199.233.217.200])
	(using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
	(Client CN "mail.NetBSD.org", Issuer "mail.NetBSD.org CA" (not verified))
	by mollari.NetBSD.org (Postfix) with ESMTPS id 211D57A153
	for <gnats-bugs@gnats.NetBSD.org>; Mon, 25 Jun 2018 07:00:20 +0000 (UTC)
Message-Id: <20180625070011.73C055CC854@emmas.aprisoft.de>
Date: Mon, 25 Jun 2018 09:00:11 +0200 (CEST)
From: martin@NetBSD.org
Reply-To: martin@NetBSD.org
To: gnats-bugs@NetBSD.org
Subject: crash in xfsettingsd
X-Send-Pr-Version: 3.95

>Number:         53397
>Category:       pkg
>Synopsis:       crash in xfsettingsd
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    bsiegert
>State:          feedback
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Mon Jun 25 07:05:00 +0000 2018
>Closed-Date:    
>Last-Modified:  Fri Nov 09 12:40:00 +0000 2018
>Originator:     Martin Husemann
>Release:        NetBSD 8.99.19
>Organization:
The NetBSD Foundation, Inc.
>Environment:
System: NetBSD whoever-brings-the-night.aprisoft.de 8.99.19 NetBSD 8.99.19 (WHOEVER) #230: Sat Jun 23 08:21:35 CEST 2018 martin@seven-days-to-the-wolves.aprisoft.de:/work/src/sys/arch/sparc64/compile/WHOEVER sparc64
Architecture: sparc64
Machine: sparc64
>Description:

I get xfsettingsd core dumps:

Core was generated by `xfsettingsd'.
Program terminated with signal SIGSEGV, Segmentation fault.
#0  0x0000000042a15e74 in up_exported_daemon_get_lid_is_closed ()
   from /usr/pkg/lib/libupower-glib.so.3
[Current thread is 1 (process 1)]
(gdb) bt
#0  0x0000000042a15e74 in up_exported_daemon_get_lid_is_closed ()
   from /usr/pkg/lib/libupower-glib.so.3
(gdb) x/16i $pc
=> 0x42a15e74 <up_exported_daemon_get_lid_is_closed+20>:        
(gdb) info reg i0
i0             0x0      0

so a NULL deref.

>How-To-Repeat:
s/a

>Fix:
n/a

>Release-Note:

>Audit-Trail:
From: Martin Husemann <martin@duskware.de>
To: gnats-bugs@NetBSD.org
Cc: 
Subject: Re: pkg/53397: crash in xfsettingsd
Date: Tue, 26 Jun 2018 08:23:22 +0200

 Here are details with debug info:

 Core was generated by `xfsettingsd'.
 Program terminated with signal SIGSEGV, Segmentation fault.
 #0  0x0000000042a15e74 in up_exported_daemon_get_lid_is_closed (object=0x0)
     at up-daemon-generated.c:747
 747       return UP_EXPORTED_DAEMON_GET_IFACE (object)->get_lid_is_closed (object);

 This seems to be called from:

 gboolean
 up_client_get_lid_is_closed (UpClient *client)
 {
         g_return_val_if_fail (UP_IS_CLIENT (client), FALSE);
         return up_exported_daemon_get_lid_is_closed (client->priv->proxy);
 }

 and when running xfsettingsd manually:

  > xfsettingsd --replace
  >

 (xfsettingsd:233): xfsettingsd-WARNING **: 08:21:48.919: Property "/Gdk/WindowScalingFactor" has an unsupported type "guint".

 (xfsettingsd:233): libupower-glib-WARNING **: 08:21:49.808: Couldn't connect to proxy: Could not connect: No such file or directory


 Now this is a desktop machine and it has no lid - but I guess this is all
 lost somewhere in the stupid dbus magic behind this.

 Martin

From: Martin Husemann <martin@duskware.de>
To: gnats-bugs@NetBSD.org
Cc: 
Subject: Re: pkg/53397: crash in xfsettingsd
Date: Tue, 26 Jun 2018 08:29:43 +0200

 This patch seems to help, and it makes the "Appearance" applet work a bit
 better.

 Martin

 --- ./libupower-glib/up-client.c.orig
 +++ ./libupower-glib/up-client.c
 @@ -205,6 +205,7 @@ gboolean
  up_client_get_lid_is_closed (UpClient *client)
  {
  	g_return_val_if_fail (UP_IS_CLIENT (client), FALSE);
 +	if (!client->priv || !client->priv->proxy) return FALSE;
  	return up_exported_daemon_get_lid_is_closed (client->priv->proxy);
  }


Responsible-Changed-From-To: pkg-manager->youri
Responsible-Changed-By: martin@NetBSD.org
Responsible-Changed-When: Tue, 26 Jun 2018 06:32:28 +0000
Responsible-Changed-Why:
Over to maintainer


State-Changed-From-To: open->analyzed
State-Changed-By: martin@NetBSD.org
State-Changed-When: Tue, 26 Jun 2018 06:32:28 +0000
State-Changed-Why:
Partially analyzed (unclear if suggested fix is the proper one)


From: David Holland <dholland-pbugs@netbsd.org>
To: gnats-bugs@NetBSD.org
Cc: 
Subject: Re: pkg/53397: crash in xfsettingsd
Date: Fri, 20 Jul 2018 06:57:18 +0000

 On Mon, Jun 25, 2018 at 07:05:00AM +0000, martin@NetBSD.org wrote:
  > #0  0x0000000042a15e74 in up_exported_daemon_get_lid_is_closed ()
  >    from /usr/pkg/lib/libupower-glib.so.3
  > (gdb) x/16i $pc
  > => 0x42a15e74 <up_exported_daemon_get_lid_is_closed+20>:        
  > (gdb) info reg i0
  > i0             0x0      0
  > 
  > so a NULL deref.

 Is this the same as 53455?

 -- 
 David A. Holland
 dholland@netbsd.org

Responsible-Changed-From-To: youri->bsiegert
Responsible-Changed-By: bsiegert@NetBSD.org
Responsible-Changed-When: Fri, 20 Jul 2018 12:12:48 +0000
Responsible-Changed-Why:
take


State-Changed-From-To: analyzed->feedback
State-Changed-By: bsiegert@NetBSD.org
State-Changed-When: Fri, 20 Jul 2018 12:12:48 +0000
State-Changed-Why:
I recently committed a patch to sysutils/upower.
Could you test if the problem still occurs when using the new version?


From: Benny Siegert <bsiegert@netbsd.org>
To: gnats-bugs@netbsd.org, youri@netbsd.org, pkgsrc-bugs@netbsd.org, 
	gnats-admin@netbsd.org, Martin Husemann <martin@netbsd.org>, 
	Martin Husemann <martin@duskware.de>
Cc: 
Subject: Re: pkg/53397 (crash in xfsettingsd)
Date: Fri, 9 Nov 2018 13:32:06 +0100

 Martin: does xfsettingsd still crash for you?

>Unformatted:

NetBSD Home
NetBSD PR Database Search

(Contact us) $NetBSD: query-full-pr,v 1.43 2018/01/16 07:36:43 maya Exp $
$NetBSD: gnats_config.sh,v 1.9 2014/08/02 14:16:04 spz Exp $
Copyright © 1994-2017 The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.