pg.ddx.io pgsql-committers@postgresql.org mailing list archivehelp / color / mirror / Atom feed
pgsql: Fix bug where GIN scan keys were not initialized with gin_fuzzy_ 5+ messages / 1 participants [nested] [flat]
* pgsql: Fix bug where GIN scan keys were not initialized with gin_fuzzy_ @ 2015-01-29 17:46 Heikki Linnakangas <heikki.linnakangas@iki.fi> 0 siblings, 0 replies; 5+ messages in thread From: Heikki Linnakangas @ 2015-01-29 17:46 UTC (permalink / raw) To: pgsql-committers Fix bug where GIN scan keys were not initialized with gin_fuzzy_search_limit. When gin_fuzzy_search_limit was used, we could jump out of startScan() without calling startScanKey(). That was harmless in 9.3 and below, because startScanKey()() didn't do anything interesting, but in 9.4 it initializes information needed for skipping entries (aka GIN fast scans), and you readily get a segfault if it's not done. Nevertheless, it was clearly wrong all along, so backpatch all the way to 9.1 where the early return was introduced. (AFAICS startScanKey() did nothing useful in 9.3 and below, because the fields it initialized were already initialized in ginFillScanKey(), but I don't dare to change that in a minor release. ginFillScanKey() is always called in gingetbitmap() even though there's a check there to see if the scan keys have already been initialized, because they never are; ginrescan() free's them.) In the passing, remove unnecessary if-check from the second inner loop in startScan(). We already check in the first loop that the condition is true for all entries. Reported by Olaf Gawenda, bug #12694, Backpatch to 9.1 and above, although AFAICS it causes a live bug only in 9.4. Branch ------ master Details ------- http://git.postgresql.org/pg/commitdiff/31ed42b9a3ea45a76cd78b29ee3b111b5ea0dbf3 Modified Files -------------- src/backend/access/gin/ginget.c | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 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] 5+ messages in thread
* pgsql: Fix bug where GIN scan keys were not initialized with gin_fuzzy_ @ 2015-01-29 17:46 Heikki Linnakangas <heikki.linnakangas@iki.fi> 0 siblings, 0 replies; 5+ messages in thread From: Heikki Linnakangas @ 2015-01-29 17:46 UTC (permalink / raw) To: pgsql-committers Fix bug where GIN scan keys were not initialized with gin_fuzzy_search_limit. When gin_fuzzy_search_limit was used, we could jump out of startScan() without calling startScanKey(). That was harmless in 9.3 and below, because startScanKey()() didn't do anything interesting, but in 9.4 it initializes information needed for skipping entries (aka GIN fast scans), and you readily get a segfault if it's not done. Nevertheless, it was clearly wrong all along, so backpatch all the way to 9.1 where the early return was introduced. (AFAICS startScanKey() did nothing useful in 9.3 and below, because the fields it initialized were already initialized in ginFillScanKey(), but I don't dare to change that in a minor release. ginFillScanKey() is always called in gingetbitmap() even though there's a check there to see if the scan keys have already been initialized, because they never are; ginrescan() free's them.) In the passing, remove unnecessary if-check from the second inner loop in startScan(). We already check in the first loop that the condition is true for all entries. Reported by Olaf Gawenda, bug #12694, Backpatch to 9.1 and above, although AFAICS it causes a live bug only in 9.4. Branch ------ REL9_4_STABLE Details ------- http://git.postgresql.org/pg/commitdiff/28a37deab30b6946558de3cafe78daa4823e23c3 Modified Files -------------- src/backend/access/gin/ginget.c | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 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] 5+ messages in thread
* pgsql: Fix bug where GIN scan keys were not initialized with gin_fuzzy_ @ 2015-01-29 17:46 Heikki Linnakangas <heikki.linnakangas@iki.fi> 0 siblings, 0 replies; 5+ messages in thread From: Heikki Linnakangas @ 2015-01-29 17:46 UTC (permalink / raw) To: pgsql-committers Fix bug where GIN scan keys were not initialized with gin_fuzzy_search_limit. When gin_fuzzy_search_limit was used, we could jump out of startScan() without calling startScanKey(). That was harmless in 9.3 and below, because startScanKey()() didn't do anything interesting, but in 9.4 it initializes information needed for skipping entries (aka GIN fast scans), and you readily get a segfault if it's not done. Nevertheless, it was clearly wrong all along, so backpatch all the way to 9.1 where the early return was introduced. (AFAICS startScanKey() did nothing useful in 9.3 and below, because the fields it initialized were already initialized in ginFillScanKey(), but I don't dare to change that in a minor release. ginFillScanKey() is always called in gingetbitmap() even though there's a check there to see if the scan keys have already been initialized, because they never are; ginrescan() free's them.) In the passing, remove unnecessary if-check from the second inner loop in startScan(). We already check in the first loop that the condition is true for all entries. Reported by Olaf Gawenda, bug #12694, Backpatch to 9.1 and above, although AFAICS it causes a live bug only in 9.4. Branch ------ REL9_3_STABLE Details ------- http://git.postgresql.org/pg/commitdiff/1c2774f3771353cac002ffcb4325331a20613305 Modified Files -------------- src/backend/access/gin/ginget.c | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 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] 5+ messages in thread
* pgsql: Fix bug where GIN scan keys were not initialized with gin_fuzzy_ @ 2015-01-29 17:46 Heikki Linnakangas <heikki.linnakangas@iki.fi> 0 siblings, 0 replies; 5+ messages in thread From: Heikki Linnakangas @ 2015-01-29 17:46 UTC (permalink / raw) To: pgsql-committers Fix bug where GIN scan keys were not initialized with gin_fuzzy_search_limit. When gin_fuzzy_search_limit was used, we could jump out of startScan() without calling startScanKey(). That was harmless in 9.3 and below, because startScanKey()() didn't do anything interesting, but in 9.4 it initializes information needed for skipping entries (aka GIN fast scans), and you readily get a segfault if it's not done. Nevertheless, it was clearly wrong all along, so backpatch all the way to 9.1 where the early return was introduced. (AFAICS startScanKey() did nothing useful in 9.3 and below, because the fields it initialized were already initialized in ginFillScanKey(), but I don't dare to change that in a minor release. ginFillScanKey() is always called in gingetbitmap() even though there's a check there to see if the scan keys have already been initialized, because they never are; ginrescan() free's them.) In the passing, remove unnecessary if-check from the second inner loop in startScan(). We already check in the first loop that the condition is true for all entries. Reported by Olaf Gawenda, bug #12694, Backpatch to 9.1 and above, although AFAICS it causes a live bug only in 9.4. Branch ------ REL9_2_STABLE Details ------- http://git.postgresql.org/pg/commitdiff/61729e99d4653d55a2f093dd9bda2c06a1a93135 Modified Files -------------- src/backend/access/gin/ginget.c | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 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] 5+ messages in thread
* pgsql: Fix bug where GIN scan keys were not initialized with gin_fuzzy_ @ 2015-01-29 17:46 Heikki Linnakangas <heikki.linnakangas@iki.fi> 0 siblings, 0 replies; 5+ messages in thread From: Heikki Linnakangas @ 2015-01-29 17:46 UTC (permalink / raw) To: pgsql-committers Fix bug where GIN scan keys were not initialized with gin_fuzzy_search_limit. When gin_fuzzy_search_limit was used, we could jump out of startScan() without calling startScanKey(). That was harmless in 9.3 and below, because startScanKey()() didn't do anything interesting, but in 9.4 it initializes information needed for skipping entries (aka GIN fast scans), and you readily get a segfault if it's not done. Nevertheless, it was clearly wrong all along, so backpatch all the way to 9.1 where the early return was introduced. (AFAICS startScanKey() did nothing useful in 9.3 and below, because the fields it initialized were already initialized in ginFillScanKey(), but I don't dare to change that in a minor release. ginFillScanKey() is always called in gingetbitmap() even though there's a check there to see if the scan keys have already been initialized, because they never are; ginrescan() free's them.) In the passing, remove unnecessary if-check from the second inner loop in startScan(). We already check in the first loop that the condition is true for all entries. Reported by Olaf Gawenda, bug #12694, Backpatch to 9.1 and above, although AFAICS it causes a live bug only in 9.4. Branch ------ REL9_1_STABLE Details ------- http://git.postgresql.org/pg/commitdiff/37e0f13f266d7dc6d9e0a5eaadbacbb01d68db61 Modified Files -------------- src/backend/access/gin/ginget.c | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 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] 5+ messages in thread
end of thread, other threads:[~2015-01-29 17:46 UTC | newest] Thread overview: 5+ messages (download: mbox mbox.gz follow: Atom feed) -- links below jump to the message on this page -- 2015-01-29 17:46 pgsql: Fix bug where GIN scan keys were not initialized with gin_fuzzy_ Heikki Linnakangas <heikki.linnakangas@iki.fi> 2015-01-29 17:46 pgsql: Fix bug where GIN scan keys were not initialized with gin_fuzzy_ Heikki Linnakangas <heikki.linnakangas@iki.fi> 2015-01-29 17:46 pgsql: Fix bug where GIN scan keys were not initialized with gin_fuzzy_ Heikki Linnakangas <heikki.linnakangas@iki.fi> 2015-01-29 17:46 pgsql: Fix bug where GIN scan keys were not initialized with gin_fuzzy_ Heikki Linnakangas <heikki.linnakangas@iki.fi> 2015-01-29 17:46 pgsql: Fix bug where GIN scan keys were not initialized with gin_fuzzy_ Heikki Linnakangas <heikki.linnakangas@iki.fi>
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