NetBSD Problem Report #29547

From syn@sceen.net  Sun Feb 27 16:36:40 2005
Return-Path: <syn@sceen.net>
Received: from mail.sceen.net (sceen.net [213.41.131.45])
	by narn.netbsd.org (Postfix) with ESMTP id 7097C63B104
	for <gnats-bugs@gnats.netbsd.org>; Sun, 27 Feb 2005 16:36:39 +0000 (UTC)
Message-Id: <20050227163630.6A6483B341@kenobi>
Date: Sun, 27 Feb 2005 17:36:30 +0100 (CET)
From: syn@sceen.net
Reply-To: syn@sceen.net
To: gnats-bugs@netbsd.org
Subject: chat/centericq bus error (c++ std class problem)
X-Send-Pr-Version: 3.95

>Number:         29547
>Category:       pkg
>Synopsis:       chat/centericq bus error (c++ std class problem)
>Confidential:   no
>Severity:       serious
>Priority:       low
>Responsible:    pkg-manager
>State:          closed
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Sun Feb 27 16:37:00 +0000 2005
>Closed-Date:    Sun Apr 08 05:24:24 +0000 2012
>Last-Modified:  Sun Apr 08 05:24:24 +0000 2012
>Originator:     syn@sceen.net
>Release:        NetBSD 1.6.2_STABLE
>Organization:
Richard Braun
>Environment:
System: NetBSD kenobi 1.6.2_STABLE NetBSD 1.6.2_STABLE (KENOBI) #0: Sun Feb 13 04:28:23 CET 2005 syn@kenobi:/mnt/sd1a/src/sys/arch/sparc64/compile/KENOBI sparc64
Architecture: sparc64
Machine: sparc64
>Description:
When using centericq on sparc64 (compiled with gcc 3.3.5), the program
crashes with SIGBUS. Here is a stack backtrace :

Program received signal SIGBUS, Bus error.
0x2cf27c in std::string* std::__uninitialized_fill_n_aux<std::string*, unsigned long, std::string>(std::string*, unsigned long, std::string const&, __false_type) ()
(gdb) bt
#0  0x2cf27c in std::string* std::__uninitialized_fill_n_aux<std::string*, unsigned long, std::string>(std::string*, unsigned long, std::string const&, __false_type) ()
#1  0x153090 in std::basic_string<char, std::char_traits<char>, std::allocator<char> > std::operator+<char, std::char_traits<char>, std::allocator<char> >(char const*, std::basic_string<char, std::char_traits<char>, std::allocator<char> > const&) ()
#2  0x1c8b54 in main ()
#3  0x1c74b8 in main ()
#4  0x107f24 in _init ()
(gdb) 

What I did is :
start centericq
select terminated
press enter
select terminated
press enter
and then, sigbus

From what is showed, the problems seems to be in the std class.

I can provide a shell account on the box for whoever is willing to
debug this.

>How-To-Repeat:

>Fix:

Unknown
>Release-Note:

>Audit-Trail:
From: Martin Husemann <martin@duskware.de>
To: gnats-bugs@NetBSD.org
Cc: 
Subject: Re: pkg/29547: centericq+sparc64+gcc3 = boom
Date: Fri, 18 Mar 2005 09:34:26 +0100

 This is not a stdlib problem. If you compile a debug version and run it
 in gdb, you see the obvious problem:

 In kkconsui-0.1/src/dialogbox.cc there is this function:

 bool dialogbox::open(int &menuitem, int &baritem, void **ref)

 in line 101 you'll find: if(ref) *ref = r;
 this is where the crash happens. The caller at this point is
 accountmanager.cc:155:

    fin = !db.open(n, b, (void **) &citem) || (b == 1);

 and looking some pages above you'll find that citem is of type int.

 Now sizeof(int) != sizeof(void*). Boom.

 Martin

State-Changed-From-To: open->closed
State-Changed-By: dholland@NetBSD.org
State-Changed-When: Sun, 08 Apr 2012 05:24:24 +0000
State-Changed-Why:
centericq no longer builds and is expected to be removed in the near
future. If you care about this (and for some reason can't use
centerim instead) write in and let us know.


>Unformatted:

NetBSD Home
NetBSD PR Database Search

(Contact us) $NetBSD: query-full-pr,v 1.51 2026/08/10 02:28:17 riastradh Exp $
$NetBSD: gnats_config.sh,v 1.10 2026/05/13 22:00:09 riastradh Exp $
Copyright © 1994-2026 The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.