Summary: | Crash in Sublime::View when creating a non-C++ file in a project | ||
---|---|---|---|
Product: | [Developer tools] kdevplatform | Reporter: | Nicolai Hähnle <nhaehnle> |
Component: | sublime | Assignee: | kdevelop-bugs-null |
Status: | RESOLVED FIXED | ||
Severity: | crash | ||
Priority: | NOR | ||
Version: | git master | ||
Target Milestone: | --- | ||
Platform: | Compiled Sources | ||
OS: | Linux | ||
Latest Commit: | http://commits.kde.org/kdevplatform/c394eb8dd2fcd090e661695bd318c35af6578024 | Version Fixed In: |
Description
Nicolai Hähnle
2014-12-19 18:42:08 UTC
Git commit fa8ab02ebd8f88c7214538cdf4b7e8c1ac07cd98 by Nicolai Hähnle. Committed on 19/12/2014 at 12:28. Pushed by nicolaih into branch 'master'. sublime: prevent accidentally adding nullptrs to ContainerPrivate::viewForWidget The likely culprit here is using operator[] to access a map, which implicitly creates an entry containing a null view. I have audited all other accesses of viewForWidget with operator[] to verify that they happen in a context where the entry is non-null (either because the access is used to assign a non-null view pointer or because the access is guaranteed to crash or abort immediately if it would create an incorrect nullptr entry). REVIEW: 121600 M +2 -2 sublime/container.cpp http://commits.kde.org/kdevplatform/fa8ab02ebd8f88c7214538cdf4b7e8c1ac07cd98 Git commit c394eb8dd2fcd090e661695bd318c35af6578024 by Kevin Funk, on behalf of Nicolai Hähnle. Committed on 19/12/2014 at 12:28. Pushed by kfunk into branch '1.7'. sublime: prevent accidentally adding nullptrs to ContainerPrivate::viewForWidget The likely culprit here is using operator[] to access a map, which implicitly creates an entry containing a null view. I have audited all other accesses of viewForWidget with operator[] to verify that they happen in a context where the entry is non-null (either because the access is used to assign a non-null view pointer or because the access is guaranteed to crash or abort immediately if it would create an incorrect nullptr entry). REVIEW: 121600 (cherry picked from commit fa8ab02ebd8f88c7214538cdf4b7e8c1ac07cd98) M +2 -2 sublime/container.cpp http://commits.kde.org/kdevplatform/c394eb8dd2fcd090e661695bd318c35af6578024 |