Your message dated Fri, 25 Mar 2005 18:17:12 -0500
with message-id <[EMAIL PROTECTED]>
and subject line Bug#285431: fixed in libnss-pgsql 1.3
has caused the attached Bug report to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what I am
talking about this indicates a serious mail system misconfiguration
somewhere.  Please contact me immediately.)

Debian bug tracking system administrator
(administrator, Debian Bugs database)

--------------------------------------
Received: (at submit) by bugs.debian.org; 13 Dec 2004 08:08:17 +0000
>From [EMAIL PROTECTED] Mon Dec 13 00:08:17 2004
Return-path: <[EMAIL PROTECTED]>
Received: from oracle.bridgewayconsulting.com.au [203.56.14.38] 
        by spohr.debian.org with esmtp (Exim 3.35 1 (Debian))
        id 1CdlFg-0004yH-00; Mon, 13 Dec 2004 00:08:16 -0800
Received: from amidala (dsl-202-72-159-76.wa.westnet.com.au [202.72.159.76])
        (using TLSv1 with cipher EDH-RSA-DES-CBC3-SHA (168/168 bits))
        (No client certificate requested)
        by oracle.bridgewayconsulting.com.au (Postfix) with ESMTP id 6E7BA1F8002
        for <[EMAIL PROTECTED]>; Mon, 13 Dec 2004 16:08:31 +0800 (WST)
Received: by amidala (Postfix, from userid 1000)
        id 9AD1AC; Mon, 13 Dec 2004 16:08:03 +0800 (WST)
Date: Mon, 13 Dec 2004 16:08:03 +0800
From: Bernard Blackham <[EMAIL PROTECTED]>
To: [EMAIL PROTECTED]
Subject: libnss-pgsql gives SIGBUS on sparc
Message-ID: <[EMAIL PROTECTED]>
Mime-Version: 1.0
Content-Type: multipart/mixed; boundary="YZ5djTAD1cGYuMQK"
Content-Disposition: inline
Organization: Dagobah Systems
User-Agent: Mutt/1.5.6+20040803i
Delivered-To: [EMAIL PROTECTED]
X-Spam-Checker-Version: SpamAssassin 2.60-bugs.debian.org_2004_03_25 
        (1.212-2003-09-23-exp) on spohr.debian.org
X-Spam-Status: No, hits=-8.0 required=4.0 tests=BAYES_00,HAS_PACKAGE 
        autolearn=no version=2.60-bugs.debian.org_2004_03_25
X-Spam-Level: 


--YZ5djTAD1cGYuMQK
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline

Package: libnss-pgsql1
Version: 1.0.2-1.4

On sparc, programs such as "id" give a SIGBUS when using
libnss-pgsql:

spark:/# id bernard
Bus error
spark:/# 

GDB backtrace looks like this:
Program received signal SIGBUS, Bus error.
[Switching to Thread 16384 (LWP 9745)]
copy_attrval_n (res=0x1, attr=0x2c321 "bernard", valptr=0x2c301,
    buffer=0xefffea3c, buflen=0xefffea40, row=7) at backend.c:117
117             *valptr = *buffer;
(gdb) bt
#0  copy_attrval_n (res=0x1, attr=0x2c321 "bernard", valptr=0x2c301,
    buffer=0xefffea3c, buflen=0xefffea40, row=7) at backend.c:117
#1  0x501e6404 in getgroupmem (gid=1, result=0x50173f84, buffer=0x2c321,
    buflen=1007) at backend.c:183
#2  0x501e6518 in res2grp (res=0x2ca20, result=0x50173f84, buffer=0x2c301 ":",
    buflen=1015) at backend.c:223
#3  0x501e6b08 in backend_getgrgid (gid=0, result=0x50173f84,
    buffer=0x2c2f8 "bernard", buflen=182816, errnop=0x501731b8)
    at backend.c:468
#4  0x501e5cac in _nss_pgsql_getgrgid_r (gid=10002, result=0x50173f84,
    buffer=0x2c2f8 "bernard", buflen=1024, errnop=0x501731b8)
    at interface.c:193
#5  0x500d8f98 in getgrgid_r () from /lib/libc.so.6
#6  0x500d8888 in getgrgid () from /lib/libc.so.6
#7  0x00011540 in ?? ()

A patch that works for me is attached. I'm not sure if this is the
correct way to do it, but it resolves the bug. I'm happy to provide
any more information if needed.

Bernard.

--YZ5djTAD1cGYuMQK
Content-Type: text/plain; charset=us-ascii
Content-Disposition: attachment; filename="libnss-pgsqlfix.diff"

--- libnss-pgsql-1.0.2/src/backend.c    2004-12-13 16:01:04.000000000 +0800
+++ libnss-pgsql-1.0.2/src/backend.c.new        2004-12-13 16:01:19.000000000 
+0800
@@ -172,10 +172,15 @@ enum nss_status getgroupmem(gid_t gid,
                goto BAIL_OUT;
        }
 
+       /* realign the buffer on a 4-byte boundary */
+       buflen -= 4-((long)buffer & 0x3);
+       buffer += 4-((long)buffer & 0x3);
+
        result->gr_mem = (char**)buffer;
 
-       buffer += ptrsize;
-       buflen -= ptrsize;
+       /* realign the buffer on a 4-byte boundary */
+       buffer += (ptrsize+3)&(~0x3);
+       buflen -= (ptrsize+3)&(~0x3);
 
        status = NSS_STATUS_SUCCESS;
 

--YZ5djTAD1cGYuMQK--

---------------------------------------
Received: (at 285431-close) by bugs.debian.org; 25 Mar 2005 23:25:03 +0000
>From [EMAIL PROTECTED] Fri Mar 25 15:25:03 2005
Return-path: <[EMAIL PROTECTED]>
Received: from newraff.debian.org [208.185.25.31] (mail)
        by spohr.debian.org with esmtp (Exim 3.35 1 (Debian))
        id 1DEyAp-00072M-00; Fri, 25 Mar 2005 15:25:03 -0800
Received: from katie by newraff.debian.org with local (Exim 3.35 1 (Debian))
        id 1DEy3E-0000BY-00; Fri, 25 Mar 2005 18:17:12 -0500
From: Christian Bayle <[EMAIL PROTECTED]>
To: [EMAIL PROTECTED]
X-Katie: $Revision: 1.55 $
Subject: Bug#285431: fixed in libnss-pgsql 1.3
Message-Id: <[EMAIL PROTECTED]>
Sender: Archive Administrator <[EMAIL PROTECTED]>
Date: Fri, 25 Mar 2005 18:17:12 -0500
Delivered-To: [EMAIL PROTECTED]
X-Spam-Checker-Version: SpamAssassin 2.60-bugs.debian.org_2005_01_02 
        (1.212-2003-09-23-exp) on spohr.debian.org
X-Spam-Status: No, hits=-6.0 required=4.0 tests=BAYES_00,HAS_BUG_NUMBER 
        autolearn=no version=2.60-bugs.debian.org_2005_01_02
X-Spam-Level: 

Source: libnss-pgsql
Source-Version: 1.3

We believe that the bug you reported is fixed in the latest version of
libnss-pgsql, which is due to be installed in the Debian FTP archive:

libnss-pgsql1_1.3_i386.deb
  to pool/main/libn/libnss-pgsql/libnss-pgsql1_1.3_i386.deb
libnss-pgsql_1.3.dsc
  to pool/main/libn/libnss-pgsql/libnss-pgsql_1.3.dsc
libnss-pgsql_1.3.tar.gz
  to pool/main/libn/libnss-pgsql/libnss-pgsql_1.3.tar.gz



A summary of the changes between this version and the previous one is
attached.

Thank you for reporting the bug, which will now be closed.  If you
have further comments please address them to [EMAIL PROTECTED],
and the maintainer will reopen the bug report if appropriate.

Debian distribution maintenance software
pp.
Christian Bayle <[EMAIL PROTECTED]> (supplier of updated libnss-pgsql package)

(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing [EMAIL PROTECTED])


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Format: 1.7
Date: Fri, 25 Mar 2005 22:58:54 +0100
Source: libnss-pgsql
Binary: libnss-pgsql1
Architecture: source i386
Version: 1.3
Distribution: unstable
Urgency: low
Maintainer: Wichert Akkerman <[EMAIL PROTECTED]>
Changed-By: Christian Bayle <[EMAIL PROTECTED]>
Description: 
 libnss-pgsql1 - name service switch module using PostgreSQL
Closes: 285431
Changes: 
 libnss-pgsql (1.3) unstable; urgency=low
 .
   * Applied a patch to remove SIGBUS error on sparc (Closes: Bug#285431)
Files: 
 6dfbe0593147ab9f68c55f00ec4fa615 670 admin extra libnss-pgsql_1.3.dsc
 8a2a404a9f02a637fc8808a59009196b 324279 admin extra libnss-pgsql_1.3.tar.gz
 357b9e5d028d90b0ee9a52504a7687db 18264 admin extra libnss-pgsql1_1.3_i386.deb

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.0 (GNU/Linux)

iD8DBQFCRJi127F1kyD6chwRAvXQAJ9SBpJgc9f43oqXalbOQE5jHFfF0QCfZn99
yopwHm1/asOu700Vt81pqnc=
=VWEh
-----END PGP SIGNATURE-----


-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to