troubleshooting pointers

Поиск
Список
Период
Сортировка
От Joe Conway
Тема troubleshooting pointers
Дата
Msg-id 3CDAB5A5.9000901@joeconway.com
обсуждение исходный текст
Ответы Re: troubleshooting pointers  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-hackers
With the current SRF patch, in certain circumstances selecting from a 
VIEW produces "Buffer Leak" warnings, while selecting from the function 
itself does not. Also the VIEW returns only one of the two expected 
rows. The same SQL function when declared as "... getfoo(int) RETURNS 
int AS ..." instead of "... getfoo(int) RETURNS *setof* int AS..." does 
not produce the warning. Any ideas what I should be focusing on to track 
this down? Does anyone have any favorite troubleshooting techniques for 
this type of problem?

Thanks,
Joe

-- sql, proretset = t, prorettype = b
DROP FUNCTION getfoo(int);
DROP
CREATE FUNCTION getfoo(int) RETURNS setof int AS 'SELECT fooid FROM foo 
WHERE fooid = $1;' LANGUAGE SQL;
CREATE
SELECT * FROM getfoo(1) AS t1; getfoo
--------      1      1
(2 rows)

DROP VIEW vw_getfoo;
DROP
CREATE VIEW vw_getfoo AS SELECT * FROM getfoo(1);
CREATE
SELECT * FROM vw_getfoo;
psql:../srf-test.sql:21: WARNING:  Buffer Leak: [055] (freeNext=-3, 
freePrev=-3, rel=16570/123204, blockNum=1, flags=0x4, refcount=1 1)
psql:../srf-test.sql:21: WARNING:  Buffer Leak: [059] (freeNext=-3, 
freePrev=-3, rel=16570/123199, blockNum=0, flags=0x85, refcount=1 1) getfoo
--------      1
(1 row)



В списке pgsql-hackers по дате отправления:

Предыдущее
От: Jean-Michel POURE
Дата:
Сообщение: Re: How much work is a native Windows application?
Следующее
От: cbbrowne@cbbrowne.com
Дата:
Сообщение: Re: How much work is a native Windows application?