Hi Peter, > The grep in pdfmom is returning a binary file hit when it encounters > the diacritic in > > .ds pdf:look(pdf:bm1) L'étranger
What does locale(1) output for you where you run this pdfmom command? > The solution is to pass the -a flag to grep. How about groff ... 2>&1 | LC_ALL=C grep '^\.ds' | groff ... BTW, pdfmom has a bug shown by that strace command I suggested. system("groff ... 2>&1 | grep '^\.ds' | groff ..."); That's a double-quoted Perl string so `\.' is escaping the dot and grep sees a plain dot for `any character'. The backslash needs doubling. $ perl -wl print "groff ... 2>&1 | grep '^\.ds' | groff ..."; print "groff ... 2>&1 | grep '^\\.ds' | groff ..."; ^D groff ... 2>&1 | grep '^.ds' | groff ... groff ... 2>&1 | grep '^\.ds' | groff ... $ > Question: why does grep treat the presence of the diacritic as cause > for saying "Binary file (standard input) matches"? Need `locale's output. :-) -- Cheers, Ralph. https://plus.google.com/+RalphCorderoy