Bug 236519 - Error log does not handle multi-line messages properly.
Summary: Error log does not handle multi-line messages properly.
Status: RESOLVED DUPLICATE of bug 100715
Alias: None
Product: PDE
Classification: Eclipse Project
Component: UI (show other bugs)
Version: 3.3.2   Edit
Hardware: All All
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: PDE-UI-Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-06-10 17:39 EDT by Dmitry Karasik CLA
Modified: 2008-06-10 21:21 EDT (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Dmitry Karasik CLA 2008-06-10 17:39:51 EDT
Start eclipse. Log 2 IStatus messages with a multi-line message, no stack trace (make sure these are the 1st 2 messages of the session at least as far as LogView.fFirstEvent is concerned)  look in the error log.

For the 1st message, only the 1st line shows up.
For the 2nd message, the 1st and 2nd lines are concatenated together.

The problem is in LogReader.parseLogFile():

1. The problem is that after the for loop, it only updates if writerState == STACK_STATE, it should also update the message if writerState == MESSAGE_STATE

2. The problem is in the code:
 StringBuffer sb = new StringBuffer(current.getMessage());
 sb.append(swriter.toString());
 current.setMessage(sb.toString().trim());

It should insert a newline between the current message and the message being appended.
Comment 1 Chris Aniszczyk CLA 2008-06-10 21:21:34 EDT

*** This bug has been marked as a duplicate of bug 100715 ***