aboutsummaryrefslogtreecommitdiff
path: root/src/backend/executor/nodeFunctionscan.c
diff options
context:
space:
mode:
authorTom Lane <tgl@sss.pgh.pa.us>2016-08-26 14:15:47 -0400
committerTom Lane <tgl@sss.pgh.pa.us>2016-08-26 14:15:47 -0400
commit8529036b53298c0555670b4a81ed7349c44aeeb4 (patch)
tree6bceafdca1af0e5f8b1050ad8232fe45abb8aca3 /src/backend/executor/nodeFunctionscan.c
parentfbf28b6b52c269188262a87247adb2c359acd6c5 (diff)
downloadpostgresql-8529036b53298c0555670b4a81ed7349c44aeeb4.tar.gz
postgresql-8529036b53298c0555670b4a81ed7349c44aeeb4.zip
Fix assorted small bugs in ThrowErrorData().
Copy the palloc'd strings into the correct context, ie ErrorContext not wherever the source ErrorData is. This would be a large bug, except that it appears that all catchers of thrown errors do either EmitErrorReport or CopyErrorData before doing anything that would cause transient memory contexts to be cleaned up. Still, it's wrong and it will bite somebody someday. Fix failure to copy cursorpos and internalpos. Utter the appropriate incantations involving recursion_depth, so that we'll behave sanely if we get an error inside pstrdup. (In general, the body of this function ought to act like, eg, errdetail().) Per code reading induced by Jakob Egger's report.
Diffstat (limited to 'src/backend/executor/nodeFunctionscan.c')
0 files changed, 0 insertions, 0 deletions