TW-1723: task info causes segfault
- Thanks to Roman Golovin. - Calls like 'context.columns[name]' autovivify the key 'name' with a default ctor value, which ends up polluting the context.columns map with every unique attribute name, which is a lot of 'annotation_nnnnnnnnnn' attributes.
This commit is contained in:
@@ -501,10 +501,9 @@ bool Task::is_dueyear () const
|
||||
bool Task::is_udaPresent () const
|
||||
{
|
||||
for (auto& col : context.columns)
|
||||
if (col.first.compare (0, 11, "annotation_", 11) != 0)
|
||||
if (col.second->is_uda () &&
|
||||
has (col.first))
|
||||
return true;
|
||||
if (col.second->is_uda () &&
|
||||
has (col.first))
|
||||
return true;
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user