Skip site navigation (1) Skip section navigation (2)

relname.data

From: SHIOZAKI Takehiko <takehi-s(at)ascii(dot)co(dot)jp>
To: pgsql-hackers(at)postgresql(dot)org
Subject: relname.data
Date: 1998-10-29 01:48:23
Message-ID: 199810290148.KAA24319@libpc01.pb.ascii.co.jp (view raw or flat)
Thread:
Lists: pgsql-hackers
Hello!

I'm the original reporter of "vacuum crash" problem.
Thank you for your quick fix.

Now, I found another problem in nbtsearch.c.
This is my patch for it.
# But, what I want to know is why postgres reaches this FATAL status...

========================================================================
*** nbtsearch.c.orig	Tue Oct 20 16:42:59 1998
--- nbtsearch.c	Tue Oct 20 16:43:15 1998
***************
*** 217,223 ****
  										PageGetItemId(page, P_FIRSTKEY),
  										BTEqualStrategyNumber))
  							elog(FATAL, "btree: BTP_CHAIN flag was expected in %s (access = %s)",
! 								 rel->rd_rel->relname, access ? "bt_write" : "bt_read");
  						if (_bt_skeycmp(rel, keysz, scankey, page,
  										PageGetItemId(page, offmax),
  										BTEqualStrategyNumber))
--- 217,223 ----
  										PageGetItemId(page, P_FIRSTKEY),
  										BTEqualStrategyNumber))
  							elog(FATAL, "btree: BTP_CHAIN flag was expected in %s (access = %s)",
! 								 rel->rd_rel->relname.data, access ? "bt_write" : "bt_read");
  						if (_bt_skeycmp(rel, keysz, scankey, page,
  										PageGetItemId(page, offmax),
  										BTEqualStrategyNumber))
========================================================================

And with the following script, you can find suspicious lines which
have pointer type incompatibility but work *fortunately* on most
systems.

========================================================================
#/bin/sh

find PGSRC -type f -name '*.[ch]' -print |
xargs egrep -e 'rd_rel->relname' /dev/null |
egrep -v 'relname\)?\.data'
========================================================================

Regards

-- 
ASCII CORPORATION
Technical Center
SHIOZAKI Takehiko
<takehi-s(at)ascii(dot)co(dot)jp>

pgsql-hackers by date

Next:From: Bruce MomjianDate: 1998-10-29 02:35:26
Subject: Re: [HACKERS] Open 6.4 items
Previous:From: The Hermit HackerDate: 1998-10-29 00:48:34
Subject: Re: [HACKERS] Another bug in pg_operator.h

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group