forked frompostgres/postgres
- Notifications
You must be signed in to change notification settings - Fork6
Commitfb60118
committed
Avoid possible longjmp-induced logic error in PLy_trigger_build_args.
The "pltargs" variable wasn't marked volatile, which makes it unsafeto change its value within the PG_TRY block. It looks like the worstoutcome would be to fail to release a refcount on Py_None during an(improbable) error exit, which would likely go unnoticed in the field.Still, it's a bug. A one-liner fix could be to mark pltargs volatile,but on the whole it seems cleaner to arrange things so that we don'tchange its value within PG_TRY.Per report from Xing Guo. This has been there for quite awhile,so back-patch to all supported branches.Discussion:https://postgr.es/m/CACpMh+DLrk=fDv07MNpBT4J413fDAm+gmMXgi8cjPONE+jvzuw@mail.gmail.com1 parentde3c5b1 commitfb60118
1 file changed
+8
-4
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
693 | 693 | | |
694 | 694 | | |
695 | 695 | | |
696 | | - | |
| 696 | + | |
697 | 697 | | |
698 | 698 | | |
699 | 699 | | |
| |||
717 | 717 | | |
718 | 718 | | |
719 | 719 | | |
| 720 | + | |
| 721 | + | |
| 722 | + | |
| 723 | + | |
| 724 | + | |
720 | 725 | | |
721 | 726 | | |
722 | 727 | | |
| |||
860 | 865 | | |
861 | 866 | | |
862 | 867 | | |
863 | | - | |
| 868 | + | |
864 | 869 | | |
865 | 870 | | |
866 | 871 | | |
| |||
874 | 879 | | |
875 | 880 | | |
876 | 881 | | |
877 | | - | |
878 | | - | |
| 882 | + | |
879 | 883 | | |
880 | 884 | | |
881 | 885 | | |
| |||
0 commit comments
Comments
(0)