Received: from makus.postgresql.org (makus.postgresql.org [98.129.198.125]) by mail.postgresql.org (Postfix) with ESMTP id EFC1F29CEF2 for ; Wed, 18 Jul 2012 01:32:09 -0300 (ADT) Received: from sss.pgh.pa.us ([66.207.139.130]) by makus.postgresql.org with esmtp (Exim 4.72) (envelope-from ) id 1SrLvk-000593-F0 for pgsql-bugs@postgresql.org; Wed, 18 Jul 2012 04:32:09 +0000 Received: from sss2.sss.pgh.pa.us (tgl@localhost [127.0.0.1]) by sss.pgh.pa.us (8.14.5/8.14.5) with ESMTP id q6I4VrIq015722; Wed, 18 Jul 2012 00:31:53 -0400 (EDT) From: Tom Lane To: Bruce Momjian cc: Mike Wilson , pgsql-bugs@postgresql.org Subject: Re: BUG #6733: All Tables Empty After pg_upgrade (PG 9.2.0 beta 2) In-reply-to: <20120718041830.GB29910@momjian.us> References: <13290.1342133046@sss.pgh.pa.us> <20120712224929.GB25074@momjian.us> <517A874F-B310-4340-803D-EC8625C8B497@gmail.com> <20120713015241.GA15443@momjian.us> <8D0918C1-39A0-429A-96DB-997BE362141A@gmail.com> <20120717205949.GA8146@momjian.us> <1857E88C-CD2D-4C44-B04B-82256B4E9959@gmail.com> <20120717233915.GC8146@momjian.us> <20120718041830.GB29910@momjian.us> Comments: In-reply-to Bruce Momjian message dated "Wed, 18 Jul 2012 00:18:30 -0400" MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="----- =_aaaaaaaaaa0" Content-ID: <15687.1342585796.0@sss.pgh.pa.us> Date: Wed, 18 Jul 2012 00:31:53 -0400 Message-ID: <15721.1342585913@sss.pgh.pa.us> X-Pg-Spam-Score: -1.9 (-) X-Archive-Number: 201207/144 X-Sequence-Number: 33620 ------- =_aaaaaaaaaa0 Content-Type: text/plain; charset="us-ascii" Content-ID: <15687.1342585796.1@sss.pgh.pa.us> Bruce Momjian writes: > I am using git head for testing. Tom sees a few things odd in > load_directory() that might be causing some problems on Solaris, and > this is new code for 9.2 for Solaris, so that might explain it. I think > we need Tom to finish and then if you can grab our git source and test > that, it would be great! The only thing I see that looks likely to represent a platform-specific issue is the entrysize calculation. Mike, just out of curiosity, could you see if the attached patch makes things better for you? regards, tom lane ------- =_aaaaaaaaaa0 Content-Type: text/x-patch; charset="us-ascii" Content-ID: <15687.1342585796.2@sss.pgh.pa.us> Content-Description: entrysize-fix.patch Content-Transfer-Encoding: quoted-printable diff --git a/contrib/pg_upgrade/file.c b/contrib/pg_upgrade/file.c index 1dd3722142c9e83c1ec228099c3a3fd302a2179b..c886a67df43792a1692eec6b3b= 90238413e9f844 100644 *** a/contrib/pg_upgrade/file.c --- b/contrib/pg_upgrade/file.c *************** load_directory(const char *dirname, stru *** 259,265 **** return -1; } = ! entrysize =3D sizeof(struct dirent) - sizeof(direntry->d_name) + strlen(direntry->d_name) + 1; = (*namelist)[name_num] =3D (struct dirent *) malloc(entrysize); --- 259,265 ---- return -1; } = ! entrysize =3D offsetof(struct dirent, d_name) + strlen(direntry->d_name) + 1; = (*namelist)[name_num] =3D (struct dirent *) malloc(entrysize); ------- =_aaaaaaaaaa0--