mirror of
https://github.com/postgres/postgres.git
synced 2025-06-16 06:01:02 +03:00
Don't invoke arbitrary code inside a possibly-aborted transaction.
The code here previously tried to call the partitioning operator, but really the right thing to do (and the safe thing to do) is use datumIsEqual(). Amit Langote, but I expanded the comment and fixed a compiler warning.
This commit is contained in:
@ -209,6 +209,10 @@ datumTransfer(Datum value, bool typByVal, int typLen)
|
||||
* of say the representation of zero in one's complement arithmetic).
|
||||
* Also, it will probably not give the answer you want if either
|
||||
* datum has been "toasted".
|
||||
*
|
||||
* Do not try to make this any smarter than it currently is with respect
|
||||
* to "toasted" datums, because some of the callers could be working in the
|
||||
* context of an aborted transaction.
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
bool
|
||||
|
Reference in New Issue
Block a user