mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-07-07 17:15:25 +02:00
Bug 539145 - Avoid NPE in CaseBreakQuickFixFallthroughAttribute.validPositionForFallthrough()
Change-Id: I8a53691f91411bf88f95112d99c1967b1238515a
This commit is contained in:
parent
e6730c9ef0
commit
cf99170296
1 changed files with 2 additions and 0 deletions
|
@ -61,6 +61,8 @@ public class CaseBreakQuickFixFallthroughAttribute extends AbstractCaseBreakQuic
|
|||
try {
|
||||
IASTTranslationUnit ast = CModelUtil.toWorkingCopy(tu).getAST(null, ITranslationUnit.AST_SKIP_INDEXED_HEADERS);
|
||||
IASTStatement beforeCaseEnd = getStmtBeforeCaseEnd(marker, ast);
|
||||
if (beforeCaseEnd == null)
|
||||
return false;
|
||||
if (getNextStatement(beforeCaseEnd) == null)
|
||||
return false;
|
||||
} catch (CoreException | BadLocationException e) {
|
||||
|
|
Loading…
Add table
Reference in a new issue