Menu

#33 Eclipse freezes the whole system when I try to open file with the extension .bin

Release_1.0.0
open
nobody
None
5
2015-01-18
2014-01-20
Raguram
No

Eclipse under Linux platform is not opening files(with extension .bin)in Hex mode for relatively larger files(file size greater than 5MB) and is freezing the system when trying to do so. The issue is observed only in Linux environment and not in Windows. Also if the file size is in KB(Kilo Bytes) then Hex Editor is able to open it successfully without any issues, Issue occurs only for files with size greater than 5MB.

Attachment is a compressed file and the uncompressed one is about to 64 MB. when the file is opened in Eclipse(in Linux platform), it freezes the system. Need to do a hard reset and reboot to use the system.

Discussion

  • Raguram

    Raguram - 2014-02-14

    Kindly resolve this issue as soon as possible....

     
  • Randallco

    Randallco - 2014-02-23

    Hi Raguram. In order to reproduce and fix this issue, I will have to get hands on some Linux with Eclipse. It may take some time...

     
    • Raguram

      Raguram - 2014-03-12

      Hi Randallco. Can i know how long it may take to resolve this one.

       
  • Raguram

    Raguram - 2014-03-24

    Hi Randallco. Sorry for interrupting you. May i know when it will be resolved(i.e..,any schedule ?). Anticipating your response.

    Thanks,
    Raguram M

     
  • Raguram

    Raguram - 2014-05-05

    Hi Randallco.

    Hereby i post my findings about this issue in EHEP plugin (in Linux environment), the issue actually takes place upon invoking of the below line:

    Line #: hexEditorControl.getHexTable().pack();
    in createPartControl() method of HexEditor.java

    This line is taking a huge time to complete execution, that's why eclipse appears to be freezed when tried to open a binary file in Hex Editor mode. If we comment out this line and when tried opening the file, the file is opening immediately (in Hex mode). I'm not sure why this happens only in Linux and not in Windows environment.
    Kindly look into this issue.

    Also if a file is successfully opened in Hex mode then performing a scroll operation over the file (or trying to perform a close operation on that file) eclipse response was very slow. Unable to root cause these issues.

    I'd would be very thankful if these issues are resolved at the earliest.

    Thanks,
    Raguram

     
  • Raguram

    Raguram - 2014-06-03

    Hi Randallco,
    I think the problem is with SWT classes used in Linux, the problem is with the below method:

    private void determineVisibleRows() {

    Line #: int numVisible = table.getClientArea().height / table.getItemHeight();
    visibleRows.x = table.getVerticalBar().getSelection();
    visibleRows.y = Math.min(visibleRows.x + numVisible - 1, table.getItemCount() - 1);
    if (EhepPlugin.isDebugMode())
    System.out.println("visibleRows: " + Integer.toHexString(visibleRows.x) + "-" + Integer.toHexString(visibleRows.y) + " numvisi:" + numVisible); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
    }

    In Line #, table.getClientArea().height is computed wrongly in Linux (height is coming around Lakhs) due to which Eclipse freezes.

    Kindly provide me a solution for this fix..

    I'm also attaching a binary file for reproducing the same..

     

    Last edit: Raguram 2014-06-03
  • Raguram

    Raguram - 2014-06-05

    Hi Randall,
    As stated in my previous comment, the issue is with SWT classes (of Linux) where the getClientArea() method is been computed incorrectly. So i tried invoking the same method from its associated parent's display and found that it was working good.
    i.e.., i replaced the Line # (of my previous comment) with the following one:

    int numVisible = table.getDisplay().getClientArea().height / table.getItemHeight();

    and observed that the binary file was opening instantly.
    I've also attached the modified file along with this comment.

    Kindly review and provide your feedback..

    Thanks,
    Raguram

     
  • Raguram

    Raguram - 2014-06-10

    Hi Randall,

    Kindly provide your reply for the fix done.

    Thanks.

     
  • Raguram

    Raguram - 2014-06-10

    Hi Randall,
    Kindly let me know how to export the EHEP sources so that i may verify the fix in release mode. Kindly help us in providing the steps for exporting the EHEP sources.
    Anticipating your response...

    Thanks..

     
  • Randallco

    Randallco - 2014-09-02

    Hi Raguram,

    Finally I found some time to fix the EHEP Plugin based on your valuable input. The attached ZIP file is a pre-release of EHEP 1.1.1. Please can you install it and test it in your Linux environment please? Then let me know whether the problem you reported is fixed.

    Thanks a lot.

    Randallco, EHEP Project

     
  • Raguram

    Raguram - 2014-09-03

    Hi Randall,

    I tried with the attachment and it opens the binary file instantly, but when attempting to perform a scroll operation [to the opened file in editor] the response is too slow [dead slow]. In order to reproduce this issue you can use the binary file [sample.bin] which I'd already attached in my previous comment [comment 6 from top].

    Thanks for your response.
    Raguram

     
  • Randallco

    Randallco - 2014-09-05

    Hi Raguram,

    Thanks for testing. I did some tests of EHEP 1.1.1-prerelease with your “sample.bin” file (30 MB) and it worked great on my PC. The file got open almost instantly, paging down/up with PgDn/PgUp keys and scrolling with mouse and scrollbar was very fast. Also inserting individual bytes with “Ins” key and deleting individual bytes with “Del” key was very fast, without any noticeable delay. I guess in your case there may be yet another bug in Eclipse/SWT libs that occurs in Linux only. Hard to say.

    Spec of my test PC:
    - Windows 7 64-bit Ultimate Edition SP1;
    - CPU Intel i7-4930MX, 8 cores, 3.20 GHz;
    - 32 GB RAM;

    Is there anything else you could try on your Linux? I don't have any Linux available...so it's hard to troubleshoot for me...

    Thanks.

    Best regards,

    Randallco

     
  • Raguram

    Raguram - 2014-09-08

    Hi Randall,

    Yes, The Bug is with Linux SWT classes only. I'd already root caused that the issue is with the Linux SWT classes only (kindly refer comment 7 in page 1). Here the client area is been wrongly computed (some compatibility issue is there b/w 'Linux SWT' classes and 'EHEP' sources). I know that this issue take place only in Linux and also posted the same as an observation in one of my previous comments. In Windows Environment this open file issue (as well as drag file issue) is not observed (I've stated this clearly in synopsis of this Issue that the issue exist only in Linux and not in Windows platform). Windows SWT classes and Linux SWT classes vary in calculating the the client area of the editor.
    

    Kindly fix this compatibility issue existing b/w Linux SWT classes and EHEP sources as we are not much aware of these.

    Thanks.
    Raguram

     
  • Raguram

    Raguram - 2014-09-23

    Hi Randall,

    Is it possible to fix the bug existing in Linux (based on the information provided) ?.
    Kindly provide your reply. I'm unable to fix this bug completely (even though I am able to open the large file in hex editor).
    Please do the needful.

    Regards,
    Raguram

     
  • Randallco

    Randallco - 2014-09-30

    Yes, I see that method "getClientArea()" is invoked multiple times in the following classes:
    - net.sourceforge.ehep.gui.HexEditorControl
    - net.sourceforge.ehep.gui.HexTable

    I will have to go through all of these instances and replace them with your suggested workaround...

     
  • Raguram

    Raguram - 2014-11-11

    Hi Randall,

    Any update ?? when this is expected to release.

     
  • Randallco

    Randallco - 2014-12-22

    Hi Raguram,

    Can you please find some Eclipse log files right after EHEP crashes?
    Usually they are located here on your file system under "<workspace-folder>/.metadata" folder, file name is ".log" with some suffixes. Look into those files and attach in here the ones that mention EHEP. Thanks.

     
  • Raguram

    Raguram - 2015-01-08

    Hi Randall,

    As already mentioned, this issue is not related to ECLIPSE CRASH and so NO LOG FILES could be found in the "<workspace>/.metadata" folder.

    As already told, the computation of the editor client area is been wrongly computed (value is greater than expected) due to which the RESPONSE TIME seems to more. It is during this period of time eclipse (or to be more precise EHEP) appears to be freezed.

    This was the actual issue and I couldn't able to find any log files (as eclipse never crashes because of this process). I guess LOG FILES will be created only if application is getting crashed. But here it is not the case and the application seems to be FREEZED and not CRASHED (i.e.., some background process is running which makes the application less responsive).

    This issue could be easily duplicated if tried in some Linux systems.
    Pl. try to duplicate the issue.

    Thanks.

     
  • Randallco

    Randallco - 2015-01-18

    Please enable logging in EHEP as follows:
    - Open Eclipse;
    - Navigate to Window -> Preferences -> General -> Editors -> Hex Editor;
    - Now mark the check box next to "Enable logging";
    - Click "OK";
    - Restart Eclipse;
    - Now reproduce the problem when Eclipse is hanged by EHEP;
    - Locate the log file under ".metadata" folder;
    - Attach it to this bug report;

     

Log in to post a comment.