forked frompostgres/postgres
- Notifications
You must be signed in to change notification settings - Fork6
Commiteb6cc85
committed
Fix management of fn_extra caching during repeated GiST index scans.
Commitd22a09d introduced official supportfor GiST consistentFns that want to cache data using the FmgrInfo fn_extrapointer: the idea was to preserve the cached values across gistrescan(),whereas formerly they'd been leaked. However, there was an oversight inthat, namely that multiple scan keys might reference the same column'sconsistentFn; the code would result in propagating the same cache valueinto multiple scan keys, resulting in crashes or wrong answers. Use aseparate array instead to ensure that each scan key keeps its own state.Per bug #8143 from Joel Roller. Back-patch to 9.2 where the bug wasintroduced.1 parent44f5bb2 commiteb6cc85
1 file changed
+29
-22
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
202 | 202 | | |
203 | 203 | | |
204 | 204 | | |
| 205 | + | |
| 206 | + | |
205 | 207 | | |
206 | 208 | | |
207 | 209 | | |
208 | 210 | | |
209 | 211 | | |
210 | 212 | | |
211 | 213 | | |
| 214 | + | |
212 | 215 | | |
213 | | - | |
214 | | - | |
215 | | - | |
216 | | - | |
217 | | - | |
218 | | - | |
| 216 | + | |
219 | 217 | | |
220 | 218 | | |
221 | 219 | | |
| |||
231 | 229 | | |
232 | 230 | | |
233 | 231 | | |
234 | | - | |
235 | | - | |
236 | | - | |
237 | | - | |
238 | 232 | | |
239 | 233 | | |
240 | 234 | | |
241 | 235 | | |
242 | 236 | | |
243 | 237 | | |
244 | 238 | | |
245 | | - | |
| 239 | + | |
| 240 | + | |
| 241 | + | |
| 242 | + | |
| 243 | + | |
| 244 | + | |
| 245 | + | |
246 | 246 | | |
247 | 247 | | |
248 | 248 | | |
249 | 249 | | |
250 | 250 | | |
251 | 251 | | |
252 | 252 | | |
| 253 | + | |
| 254 | + | |
| 255 | + | |
253 | 256 | | |
254 | 257 | | |
255 | 258 | | |
256 | 259 | | |
257 | 260 | | |
| 261 | + | |
| 262 | + | |
258 | 263 | | |
259 | 264 | | |
260 | 265 | | |
| 266 | + | |
261 | 267 | | |
262 | | - | |
263 | | - | |
264 | | - | |
265 | | - | |
266 | | - | |
267 | | - | |
| 268 | + | |
268 | 269 | | |
269 | 270 | | |
270 | 271 | | |
| |||
276 | 277 | | |
277 | 278 | | |
278 | 279 | | |
279 | | - | |
280 | | - | |
281 | 280 | | |
282 | 281 | | |
283 | 282 | | |
284 | 283 | | |
285 | | - | |
286 | | - | |
| 284 | + | |
287 | 285 | | |
288 | 286 | | |
289 | | - | |
| 287 | + | |
290 | 288 | | |
291 | 289 | | |
292 | 290 | | |
| 291 | + | |
| 292 | + | |
| 293 | + | |
| 294 | + | |
| 295 | + | |
| 296 | + | |
293 | 297 | | |
| 298 | + | |
| 299 | + | |
| 300 | + | |
294 | 301 | | |
295 | 302 | | |
296 | 303 | | |
| |||
0 commit comments
Comments
(0)