- Notifications
You must be signed in to change notification settings - Fork5k
Commit2fd3e2f
committed
Fix accidentally-harmless thinko in psqlscan_test_variable().
This code was passing literal strings to psqlscan_emit,which is quite contrary to that function's specification:"If you pass it something that is not part of the yytextstring, you are making a mistake". It accidentally workedanyway, even in non-safe_encoding mode. psqlscan_emitwould compute a garbage "reference" pointer, but wouldnever dereference that since the passed string is all-ASCII.So there's no live bug today, but that is a happenstanceoutcome of psqlscan_emit's current implementation.Let's make psqlscan_test_variable do what it's supposed to,namely append directly to the output buffer. This is justfuture-proofing against possible changes in psqlscan_emit,so I don't feel a need to back-patch.1 parent0fcf02a commit2fd3e2f
1 file changed
+2
-2
lines changedLines changed: 2 additions & 2 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
1626 | 1626 |
| |
1627 | 1627 |
| |
1628 | 1628 |
| |
1629 |
| - | |
| 1629 | + | |
1630 | 1630 |
| |
1631 | 1631 |
| |
1632 | 1632 |
| |
1633 | 1633 |
| |
1634 |
| - | |
| 1634 | + | |
1635 | 1635 |
| |
1636 | 1636 |
|
0 commit comments
Comments
(0)