Overview
| Artifact ID: | 14e4821d1b8826be152a6287370d2c4625597487 |
|---|---|
| Ticket: | 218482ffffffffffffffffffffffffffffffffff
parser modifies strings in place and interferes with literal |
| User & Date: | nobody on 2000-10-26 01:01:06 |
Changes
- assignee changed to: "nobody"
- cmimetype changed to: "text/plain"
- comment changed to:
OriginalBugID: 686 Bug Version: 8.1a2 SubmitDate: '1998-10-02' LastModified: '1998-10-02' Severity: CRIT Status: Released Submitter: stanton ChangedBy: stanton OS: All OSVersion: NA Machine: NA FixedDate: '2000-10-25' FixedInVersion: 8.1b1 ClosedDate: '1998-10-02' This bug is reproducible by running the new auto_mkindex mechanism in the Tcl library directory. The problem is that the parser modifies the string it is parsing and then restores the string when it is done. The parser also adds strings to the literal table while parsing. If it causes the literal table to expand while before it restores the string, the hash value will be incorrect and the string will be misplaced. This is a specific instance of a more general problem with code that modifies strings in place. In general strings may be cached in arbitrary ways. If a routine modifies a string in place, it must be careful to only call functions that cannot affect any other parts of the system before it restores any strings that it has modified. In this particular case, the solution is to move the code that restores the string so that it appears before any calls that affect the literal table.
- foundin changed to: "obsolete: 8.1a2"
- priority changed to: "5 Medium"
- resolution changed to: "None"
- status changed to: "Open"
- submitter changed to: "nobody"
- subsystem changed to: "10. Objects"
- title changed to:
parser modifies strings in place and interferes with literal
- type changed to: "Bug"