Author Topic: Searching in binary file  (Read 370 times)

guth

  • Senior Community Member
  • Posts: 100
  • Hero Points: 7
Searching in binary file
« on: June 05, 2019, 05:54:58 pm »
I had to open a 300MB binary file with some text strings in it. Using emacs incremental search works fine but using minifind dialog is slow. Standing at bottom of file it is even slow to open the Search menu. An occassional crash also happened using the minifind dialog at the bottom of the file.

Lee

  • SlickEdit Team Member
  • Senior Community Member
  • *
  • Posts: 1299
  • Hero Points: 130
Re: Searching in binary file
« Reply #1 on: June 05, 2019, 08:11:51 pm »
> Using emacs incremental search works fine but using minifind dialog is slow
Is it slow attempting to type or is doing the find operation on Enter?  The incremental features as you type are disabled for large files as determined by the setting Tools > Options > Editing Search > Mini window options > Maximum buffer size for incremental search.  The default maximum size is 50000kb, incremental features should be disabled for you unless you have modified this.  What type of search are you performing and are you attempting to List all occurrences?

>Standing at bottom of file it is even slow to open the Search menu.
I would suspect this is something location specific in the file you are searching, like it is attempting to resolve word at cursor or possibly attempting to get tagging info from that location.  Is this a file you can share?

> An occassional crash also happened using the minifind dialog at the bottom of the file.
By crash, do you mean the application crash or hang or does a Slick-C stack occur without bringing down the application? 

guth

  • Senior Community Member
  • Posts: 100
  • Hero Points: 7
Re: Searching in binary file
« Reply #2 on: June 09, 2019, 08:37:25 am »
I have a file with bogus data that I can provide. The thing with it is that it contains a lot of zero bytes in the beginning and end. Standing at the very end and then opening the Search menu, it says (location 99%) Searching in the message line, and it takes a long time for the menu to appear. Maybe you can reproduce by having, e.g., a 300 MB file with all zeroes?

Standing at the beginning and selecting Search menu does not give this behavior.