pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
pgsql: Fix broken error check in _hash_doinsert.
6+ messages / 1 participants
[nested] [flat]

* pgsql: Fix broken error check in _hash_doinsert.
@ 2016-12-22 19:20 Robert Haas <rhaas@postgresql.org>
  0 siblings, 0 replies; 6+ messages in thread

From: Robert Haas @ 2016-12-22 19:20 UTC (permalink / raw)
  To: pgsql-committers

Fix broken error check in _hash_doinsert.

You can't just cast a HashMetaPage to a Page, because the meta page
data is stored after the page header, not at offset 0.  Fortunately,
this didn't break anything because it happens to find hashm_bsize
at the offset at which it expects to find pd_pagesize_version, and
the values are close enough to the same that this works out.

Still, it's a bug, so back-patch to all supported versions.

Mithun Cy, revised a bit by me.

Branch
------
master

Details
-------
http://git.postgresql.org/pg/commitdiff/097e41439d69e11fb870e009b1ac64dda4f01c3d

Modified Files
--------------
src/backend/access/hash/hashinsert.c | 8 +++++---
1 file changed, 5 insertions(+), 3 deletions(-)


-- 
Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-committers


^ permalink  raw  reply  [nested|flat] 6+ messages in thread

* pgsql: Fix broken error check in _hash_doinsert.
@ 2016-12-22 19:20 Robert Haas <rhaas@postgresql.org>
  0 siblings, 0 replies; 6+ messages in thread

From: Robert Haas @ 2016-12-22 19:20 UTC (permalink / raw)
  To: pgsql-committers

Fix broken error check in _hash_doinsert.

You can't just cast a HashMetaPage to a Page, because the meta page
data is stored after the page header, not at offset 0.  Fortunately,
this didn't break anything because it happens to find hashm_bsize
at the offset at which it expects to find pd_pagesize_version, and
the values are close enough to the same that this works out.

Still, it's a bug, so back-patch to all supported versions.

Mithun Cy, revised a bit by me.

Branch
------
REL9_6_STABLE

Details
-------
http://git.postgresql.org/pg/commitdiff/17742a05110ee0015f2861e9a4e4b1158c7e69cf

Modified Files
--------------
src/backend/access/hash/hashinsert.c | 8 +++++---
1 file changed, 5 insertions(+), 3 deletions(-)


-- 
Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-committers


^ permalink  raw  reply  [nested|flat] 6+ messages in thread

* pgsql: Fix broken error check in _hash_doinsert.
@ 2016-12-22 19:20 Robert Haas <rhaas@postgresql.org>
  0 siblings, 0 replies; 6+ messages in thread

From: Robert Haas @ 2016-12-22 19:20 UTC (permalink / raw)
  To: pgsql-committers

Fix broken error check in _hash_doinsert.

You can't just cast a HashMetaPage to a Page, because the meta page
data is stored after the page header, not at offset 0.  Fortunately,
this didn't break anything because it happens to find hashm_bsize
at the offset at which it expects to find pd_pagesize_version, and
the values are close enough to the same that this works out.

Still, it's a bug, so back-patch to all supported versions.

Mithun Cy, revised a bit by me.

Branch
------
REL9_5_STABLE

Details
-------
http://git.postgresql.org/pg/commitdiff/aa04e5c3c1b1ba27d5e726d9afc291f475051ec0

Modified Files
--------------
src/backend/access/hash/hashinsert.c | 8 +++++---
1 file changed, 5 insertions(+), 3 deletions(-)


-- 
Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-committers


^ permalink  raw  reply  [nested|flat] 6+ messages in thread

* pgsql: Fix broken error check in _hash_doinsert.
@ 2016-12-22 19:20 Robert Haas <rhaas@postgresql.org>
  0 siblings, 0 replies; 6+ messages in thread

From: Robert Haas @ 2016-12-22 19:20 UTC (permalink / raw)
  To: pgsql-committers

Fix broken error check in _hash_doinsert.

You can't just cast a HashMetaPage to a Page, because the meta page
data is stored after the page header, not at offset 0.  Fortunately,
this didn't break anything because it happens to find hashm_bsize
at the offset at which it expects to find pd_pagesize_version, and
the values are close enough to the same that this works out.

Still, it's a bug, so back-patch to all supported versions.

Mithun Cy, revised a bit by me.

Branch
------
REL9_4_STABLE

Details
-------
http://git.postgresql.org/pg/commitdiff/c2f78e5e02e72e7f74f549fa07a435b1264ba308

Modified Files
--------------
src/backend/access/hash/hashinsert.c | 8 +++++---
1 file changed, 5 insertions(+), 3 deletions(-)


-- 
Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-committers


^ permalink  raw  reply  [nested|flat] 6+ messages in thread

* pgsql: Fix broken error check in _hash_doinsert.
@ 2016-12-22 19:20 Robert Haas <rhaas@postgresql.org>
  0 siblings, 0 replies; 6+ messages in thread

From: Robert Haas @ 2016-12-22 19:20 UTC (permalink / raw)
  To: pgsql-committers

Fix broken error check in _hash_doinsert.

You can't just cast a HashMetaPage to a Page, because the meta page
data is stored after the page header, not at offset 0.  Fortunately,
this didn't break anything because it happens to find hashm_bsize
at the offset at which it expects to find pd_pagesize_version, and
the values are close enough to the same that this works out.

Still, it's a bug, so back-patch to all supported versions.

Mithun Cy, revised a bit by me.

Branch
------
REL9_3_STABLE

Details
-------
http://git.postgresql.org/pg/commitdiff/603ad8ad298315cab79fa4e1c78095e4a3eca003

Modified Files
--------------
src/backend/access/hash/hashinsert.c | 8 +++++---
1 file changed, 5 insertions(+), 3 deletions(-)


-- 
Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-committers


^ permalink  raw  reply  [nested|flat] 6+ messages in thread

* pgsql: Fix broken error check in _hash_doinsert.
@ 2016-12-22 19:20 Robert Haas <rhaas@postgresql.org>
  0 siblings, 0 replies; 6+ messages in thread

From: Robert Haas @ 2016-12-22 19:20 UTC (permalink / raw)
  To: pgsql-committers

Fix broken error check in _hash_doinsert.

You can't just cast a HashMetaPage to a Page, because the meta page
data is stored after the page header, not at offset 0.  Fortunately,
this didn't break anything because it happens to find hashm_bsize
at the offset at which it expects to find pd_pagesize_version, and
the values are close enough to the same that this works out.

Still, it's a bug, so back-patch to all supported versions.

Mithun Cy, revised a bit by me.

Branch
------
REL9_2_STABLE

Details
-------
http://git.postgresql.org/pg/commitdiff/de651a6e5db25d462bde0a47cb4f8f45c45a6a6d

Modified Files
--------------
src/backend/access/hash/hashinsert.c | 8 +++++---
1 file changed, 5 insertions(+), 3 deletions(-)


-- 
Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-committers


^ permalink  raw  reply  [nested|flat] 6+ messages in thread


end of thread, other threads:[~2016-12-22 19:20 UTC | newest]

Thread overview: 6+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2016-12-22 19:20 pgsql: Fix broken error check in _hash_doinsert. Robert Haas <rhaas@postgresql.org>
2016-12-22 19:20 pgsql: Fix broken error check in _hash_doinsert. Robert Haas <rhaas@postgresql.org>
2016-12-22 19:20 pgsql: Fix broken error check in _hash_doinsert. Robert Haas <rhaas@postgresql.org>
2016-12-22 19:20 pgsql: Fix broken error check in _hash_doinsert. Robert Haas <rhaas@postgresql.org>
2016-12-22 19:20 pgsql: Fix broken error check in _hash_doinsert. Robert Haas <rhaas@postgresql.org>
2016-12-22 19:20 pgsql: Fix broken error check in _hash_doinsert. Robert Haas <rhaas@postgresql.org>

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox