Bug report (?) -- 2.10 in Linux

Started by Erik Siers, October 05, 2011, 09:49:31 PM

Previous topic - Next topic

Erik Siers

I'm pretty sure that I had TrID working on previous versions of Slackware, but when I tried running it on a clean install of 13.37 (the current version) I got this error:
Quotebash-4.1$ trid image_disp.jpeg

TrID/32 - File Identifier v2.10 - (C) 2003-11 By M.Pontello

File /usr/local/bin\triddefs.trd not found!
No definitions available! You can download an up to date
defs library from TrID's page at http://mark0.net

triddefs.trd is indeed in /usr/local/bin (as is TrID itself) -- I also copied it to /usr/local/etc and /usr/local/lib to see if that would magically fix it. (It didn't.) TrID works fine as long as the .trd file is in the current directory...  :-\

Note the backslash (\) in the listed path (/usr/local/bin\triddefs.trd). If you change the byte (in the compiled app) at 0xf6b4 (or &hf6b5 for BASIC) from "\" to "/", this problem is fixed; that tells me that this might very well be a bug. Might want to check your sources.

Mark0


Erik Siers

#2
Here's a BASIC script to patch the executable as I mentioned above. Works in Michael Haardt's bas (http://www.moria.de/~michael/bas/) and FreeBASIC; should work in pretty much any QBasic-alike, and possibly others (untested); does  NOT work in Chipmunk Basic (http://www.nicholson.com/rhn/basic/; no BINARY mode).
(patch removed; not needed for current version)

Save that to a file ("patch-trid.bas" or whatever) and then run it in the directory containing the trid executable:
    bas patch-trid.bas

This only needs to be run once -- running it again does nothing except waste your time.

Note that this is only for TrID 2.10 for Linux dated 14 Feb 2011 -- this will probably do Bad ThingsTM to other versions.

Mark0


Erik Siers