Bug 86691 - [Help Wanted] Editor displays garbage when double-clicking object file in C Project view
Summary: [Help Wanted] Editor displays garbage when double-clicking object file in C P...
Status: NEW
Alias: None
Product: CDT
Classification: Tools
Component: cdt-core (show other bugs)
Version: 2.1   Edit
Hardware: PC Windows XP
: P3 enhancement (vote)
Target Milestone: ---   Edit
Assignee: Project Inbox CLA
QA Contact: Jonah Graham CLA
URL:
Whiteboard:
Keywords: helpwanted
Depends on:
Blocks:
 
Reported: 2005-02-25 14:47 EST by David Pickens CLA
Modified: 2020-09-04 15:19 EDT (History)
3 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description David Pickens CLA 2005-02-25 14:47:11 EST
From the C/C++ Project view, if you double-click an object file or executable,
it naively loads the binary file into the text editor. It appears as garbage.
Comment 1 Uwe Stieber CLA 2006-12-21 09:28:57 EST
In case any of the "Cygwin *" binary parser is selected, the expected output is the one from the objdump utility. Even if the corresponding Cygwin*BinaryObject.getContents() returns the correct text input, the text is again lost on the way to the editor!
Comment 2 Uwe Stieber CLA 2006-12-21 09:38:10 EST
See https://bugs.eclipse.org/bugs/show_bug.cgi?id=62064. This had been fixed already once.
Comment 3 Anton Leherbauer CLA 2006-12-21 09:59:27 EST
Targetting to 4.0.
Comment 4 Anton Leherbauer CLA 2007-01-23 06:04:43 EST
I have fixed the regression of bug 62064, but this does not solve the issue in the general case. E.g. if the binary file is not opened from the Navigator view, the editor will still show garbage.
A better solution would be to create a specialized editor associated with binary files which can be opened with the usual FileEditorInput.
Comment 5 Philippe Coucaud CLA 2007-02-06 04:55:42 EST
Anton, I've just tried a recent nightly build of CDT (200702050601) with Eclipse 3.3M4, but I'm still not able to see anything else than garbage when double-clicking on an object file. I've tried opening a gcc object file both from the Navigator and the C/C++ views.

I also confirm that our users are annoyed by this behavior and we'd be interested in a customizable object editor (our tool-chain supports both ELF and a proprietary object format).
Comment 6 Anton Leherbauer CLA 2007-02-06 05:31:33 EST
(In reply to comment #5)
> Anton, I've just tried a recent nightly build of CDT (200702050601) with
> Eclipse 3.3M4, but I'm still not able to see anything else than garbage when
> double-clicking on an object file. I've tried opening a gcc object file both
> from the Navigator and the C/C++ views.

From the (Resource) Navigator view, it will always show garbage. This is in contrast to comment 4, where I stated the opposite. Sorry about the confusion.

Furthermore, the objdump output is (and was) only implemented for the Cygwin PE binary parser, ie. for ELF and other formats, the binary content is displayed.
Implementing this properly needs community help.
Comment 7 Doug Schaefer CLA 2007-08-21 10:58:02 EDT
Future means you commit to fix it in the Future. Inboxes can't make committments. Moving to '--'.