Commit 6273188
Fix batch result format corruption when using cached prepared statements
Copy ResultFormats slice before passing to SendQueryStatement, which
stores it for later use. The extended query builder reuses the backing
array on the next loop iteration, corrupting format codes stored for
earlier queries in the batch.
Fixes the bug exposed by the test in jackc#2524.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>1 parent f7b90c2 commit 6273188
1 file changed
Lines changed: 5 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1235 | 1235 | | |
1236 | 1236 | | |
1237 | 1237 | | |
1238 | | - | |
| 1238 | + | |
| 1239 | + | |
| 1240 | + | |
| 1241 | + | |
| 1242 | + | |
1239 | 1243 | | |
1240 | 1244 | | |
1241 | 1245 | | |
| |||
0 commit comments