View Issue Details
| ID | Project | Category | View Status | Date Submitted | Last Update |
|---|---|---|---|---|---|
| 0004826 | ardour | bugs | public | 2012-04-05 01:37 | 2020-04-19 20:16 |
| Reporter | ahurst | Assigned To | cth103 | ||
| Priority | normal | Severity | major | Reproducibility | have not tried |
| Status | closed | Resolution | fixed | ||
| Product Version | 3.0-beta3 | ||||
| Summary | 0004826: Invalidated iterator used | ||||
| Description | Medium impact static analysis bug: Using invalid iterator at: gtk2_ardour/tempo_lines.cc:52. The loop is right; but "i" is invalid at _lines.insert(). | ||||
| Additional Information | 38void 39TempoLines::tempo_map_changed() 40{ 41 _clean_left = DBL_MAX; 42 _clean_right = 0.0; 43 44 double_t d = 1.0; 45 // TODO: Dirty/slow, but 'needed' for zoom :( Condition "i != this->_lines.end()", taking true branch 46 for (Lines::iterator i = _lines.begin(); i != _lines.end(); d += 1.0) { 47 Lines::iterator next = i; 48 ++next; 49 i->second->property_x1() = - d; 50 i->second->property_x2() = - d; *** "erase" invalidates iterator "i". 51 _lines.erase(i); *** Using invalid iterator "i". 52 _lines.insert(make_pair(- d, i->second)); 53 i = next; 54 } 55} 56 | ||||
| Tags | No tags attached. | ||||
| Date Modified | Username | Field | Change |
|---|---|---|---|
| 2012-04-05 01:37 | ahurst | New Issue | |
| 2012-04-07 01:37 | cth103 | cost | => 0.00 |
| 2012-04-07 01:37 | cth103 | Note Added: 0013085 | |
| 2012-04-07 01:37 | cth103 | Status | new => resolved |
| 2012-04-07 01:37 | cth103 | Resolution | open => fixed |
| 2012-04-07 01:37 | cth103 | Assigned To | => cth103 |
| 2020-04-19 20:16 | system | Note Added: 0023035 | |
| 2020-04-19 20:16 | system | Status | resolved => closed |