grep 2.25 only stopped treating files as binary under the "C" locale, as
that commonly means "I don't care about the encoding". AFAIK the
behaviour did not change if you call it under a proper locale such as
sv_SE.UTF-8. If you look at the file when it's encoded in a proper
locale, it works:

$ iconv -f iso8859-1 -t utf8 /tmp/seen-binary-by-grep.txt 
vMgs            ingen lösning - the Swedish character o-umlaut
osmak           ingen lösning
smak            lösningen - the solution

(Note that the file is broken -- the first two non-ASCII ö characters
are encoded in ISO-8859-1, and the last one is UTF-8).

And as described above, binary detection also is disabled under C:

$ LC_CTYPE=C grep ning /tmp/seen-binary-by-grep.txt 
vMgs            ingen l�sning - the Swedish character o-umlaut
osmak           ingen l�sning
smak            lösningen - the solution


So this is indeed not the same bug as bug 1547466, I retitled that one to 
clarify. It's much closer to http://debbugs.gnu.org/cgi/bugreport.cgi?bug=19985.

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1535458

Title:
  [15.10 REGRESSION] Randomly wrongly detects files as binary

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/grep/+bug/1535458/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to