Mike Charnoky <noky@nextbus.com> writes:
> So, it does look like a pg_restore bug and that dataPos is
> being treated as an integer somewhere.
After digging in the CVS log I bet this is the same bug just noted a
month ago:
2004-01-03 23:02 tgl
* src/bin/pg_dump/: pg_backup_archiver.c (REL7_4_STABLE),
pg_backup_archiver.c: Fix ReadOffset() to work correctly when off_t
is wider than int.
It looks like the same patch applies to 7.3, modulo slightly different
line number. Please try it and let us know if it fixes the problem.
regards, tom lane
===================================================================
RCS file: /cvsroot//pgsql-server/src/bin/pg_dump/pg_backup_archiver.c,v
retrieving revision 1.79
retrieving revision 1.79.2.1
diff -c -r1.79 -r1.79.2.1
*** pgsql-server/src/bin/pg_dump/pg_backup_archiver.c 2003/10/20 21:05:11 1.79
--- pgsql-server/src/bin/pg_dump/pg_backup_archiver.c 2004/01/04 04:02:22 1.79.2.1
***************
*** 1425,1431 ****
for (off = 0; off < AH->offSize; off++)
{
if (off < sizeof(off_t))
! *o |= ((*AH->ReadBytePtr) (AH)) << (off * 8);
else
{
if ((*AH->ReadBytePtr) (AH) != 0)
--- 1425,1431 ----
for (off = 0; off < AH->offSize; off++)
{
if (off < sizeof(off_t))
! *o |= ((off_t) ((*AH->ReadBytePtr) (AH))) << (off * 8);
else
{
if ((*AH->ReadBytePtr) (AH) != 0)