Hi Christoph,
I applied the patch, but it didnt fix the issue ...

First I tried:
- get package source (apt-get source file)
- cp patches file into source-dir and apply patch (cd file-5.11; patch -p1 < debian-742262.patch)
- install patched package using configure/make/make install
- cp magic/magic.mgc /usr/share/file/.

=> file gives the wrong file type: (perl would be corrct)
file /var/lib/fai/config/scripts/NFS_CLIENT/10-create-directories
/var/lib/fai/config/scripts/NFS_CLIENT/10-create-directories: awk script, ASCII text


Second try:
- cd file-5.11
- rebuild the package with debuild -i -us -uc -b
- dpkg -i file_5.11-2+deb7u2_amd64.deb
- dpkg -i libmagic1_5.11-2+deb7u2_amd64.deb

=> still file doesnt give correct file type:
file /var/lib/fai/config/scripts/NFS_CLIENT/10-create-directories
/var/lib/fai/config/scripts/NFS_CLIENT/10-create-directories: awk script, ASCII text

Regards
René


On 03/21/2014 11:11 PM, Christoph Biedl wrote:
severity 742262 important
merge 742262 742265
tags 742262 confirmed
thanks

René Bleisch wrote...

I guess its somewhat related to the fix of Bug 703993
(https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=703993),
Correct.

which had something to do with awks "BEGIN{ }".
Is there now a mechanism like "if file contains BEGIN{...}$ then its
an awk-file" ?
This would then be wrong, because perl also uses a BEGIN{...} block
It's a bit more complicated: The fix for the above issue also
influenced the order patterns are checked. As a result, the awk
pattern is now checked *before* the Perl pattern. I'll try to have
that fixed by another upgrade.

For the time being, apply the patch below and rebuild the file
package. Only /usr/share/file/magic.mgc needs to be replaced. I'd be
glad if you could confirm this fixes the regression.

Re-using the old magic from 5.11-2+deb7u1 as suggested in the list is
a bad idea when checking files from unknown sources, so do this as a
last resort only.

Oh, and from your other mail:

In the meantime, I found out, that another person also submitted a bug
report about the same issue nearly at the same time
(Bug 742262, https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=742262).

We are both users of FAI, which is affected by this.
This is not entirely accurate ... Robert Schüttler told me in IRC
about the FAI mailing list thread, I filed this bug against my own
package so this is documented and people have a chance to learn about
it. You were faster :)

Sorry for the hassle, will check more thoroughly next time.

     Christoph

--
Dr. René Bleisch
University of Bern
Climate and Environmental Physics
Sidlerstr.5
3012 Bern
Switzerland

Phone: +41 31 631 34 02
Mail: [email protected]

Reply via email to