Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 321965

Summary: NPE in ProblemHover
Product: [Modeling] TMF Reporter: Benjamin Schwertfeger <benjamin.schwertfeger>
Component: XtextAssignee: Project Inbox <tmf.xtext-inbox>
Status: CLOSED FIXED QA Contact:
Severity: normal    
Priority: P3 CC: sebastian.zarnekow
Version: 1.0.0Flags: sebastian.zarnekow: helios+
Target Milestone: SR1   
Hardware: PC   
OS: Mac OS X - Carbon (unsup.)   
Whiteboard:
Attachments:
Description Flags
Check for existence of message before trimming it. sven.efftinge: iplog+

Description Benjamin Schwertfeger CLA 2010-08-06 05:29:25 EDT
Annotations like search result marker does not have a text. The ProblemHover class will exit with a NPE then and not work any more, until you reopen the editor.

1. Open any xtext editor, generated or original editor for grammars.
2. Write something bad and hover over the error marker. The message is shown.
3. Search for one word inside this file by File Search
4. See the yellow arrows beside the line with matches. Hover over them.
5. No Message is shown
6. Hover over the Errors in this file again. No Message is shown also.

An Error is also printed to the ErrorLog.
Comment 1 Benjamin Schwertfeger CLA 2010-08-06 05:31:08 EDT
Created attachment 176013 [details]
Check for existence of message before trimming it.

The message should be checked for null, before it is trimmed.
Comment 2 Sebastian Zarnekow CLA 2010-08-06 08:53:46 EDT
Patch applied. Thanks.
Comment 3 Karsten Thoms CLA 2017-09-19 17:13:30 EDT
Closing all bugs that were set to RESOLVED before Neon.0
Comment 4 Karsten Thoms CLA 2017-09-19 17:25:00 EDT
Closing all bugs that were set to RESOLVED before Neon.0