Try to avoid searching inside minified files #109

kdvolder opened this Issue Jan 7, 2013 · 2 comments


None yet

2 participants

kdvolder commented Jan 7, 2013

A possible heuristic to recognize minified files could be that they look like ascii/text files (i.e. not binary) but they contain very long 'lines' of text without linebreaks.

We could put an upper limit of maybe 1000 chars on the length of a line of text and if
a file has a line this long we abort searching (Also avoids reading these really long lines of text all into memory at once which for huge minified files could actually be problematic and cause crashes / hangs / out-of-memory).


Sounds reasonable to me.


Subsumed by #136 the line-by-line utility used there also has a mechanims to detect minified files.

@kdvolder kdvolder closed this Jan 16, 2013
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment