Commit 2fd5f59
authored
Fix crash when a special var points to another special var (#78)
When a var has a special varno (ie a negative varno), we need to resolve the
actual underlying Var, as we would otherwise end up reading random memory when
trying to access the associated RangeTblEntry. The previous code was correctly
resolving such Var, but didn't consider the possibility that the resolved Var
could itself have a special varno which needs to be resolved again.
Thanks to Kenny Chen for the report.1 parent e5e1f60 commit 2fd5f59
2 files changed
+19
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
17 | 17 | | |
18 | 18 | | |
19 | 19 | | |
| 20 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2391 | 2391 | | |
2392 | 2392 | | |
2393 | 2393 | | |
| 2394 | + | |
| 2395 | + | |
| 2396 | + | |
| 2397 | + | |
| 2398 | + | |
| 2399 | + | |
| 2400 | + | |
| 2401 | + | |
| 2402 | + | |
| 2403 | + | |
| 2404 | + | |
2394 | 2405 | | |
2395 | 2406 | | |
2396 | 2407 | | |
| |||
2437 | 2448 | | |
2438 | 2449 | | |
2439 | 2450 | | |
| 2451 | + | |
| 2452 | + | |
| 2453 | + | |
| 2454 | + | |
| 2455 | + | |
| 2456 | + | |
| 2457 | + | |
2440 | 2458 | | |
2441 | 2459 | | |
2442 | 2460 | | |
| |||
0 commit comments