Thread: pgsql: Fix bug in CONTINUE statement for PL/pgSQL: when we continue a
pgsql: Fix bug in CONTINUE statement for PL/pgSQL: when we continue a
From
neilc@svr1.postgresql.org (Neil Conway)
Date:
Log Message: ----------- Fix bug in CONTINUE statement for PL/pgSQL: when we continue a loop, we need to be careful to reset rc to PLPGSQL_RC_OK, depending on how the loop's logic is structured. If we continue a loop but it then exits without executing the loop's body again, we want to return PLPGSQL_RC_OK to our caller. Enhance the regression tests to catch this problem. Per report from Michael Fuhr. Modified Files: -------------- pgsql/src/pl/plpgsql/src: pl_exec.c (r1.147 -> r1.148) (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/pl/plpgsql/src/pl_exec.c.diff?r1=1.147&r2=1.148) pgsql/src/test/regress/expected: plpgsql.out (r1.35 -> r1.36) (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/test/regress/expected/plpgsql.out.diff?r1=1.35&r2=1.36) pgsql/src/test/regress/sql: plpgsql.sql (r1.30 -> r1.31) (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/test/regress/sql/plpgsql.sql.diff?r1=1.30&r2=1.31)