amaya 2.4 - troubles on Alpha

I took a closer look at amaya-2.4.  Various issues which I mentioned
in the past are still in the current sources - so I will not repeat
myself.  Still the biggest gotcha is that all '...handler.c' sources
from thotlib/image are basically broken as they all include a code
in this style:

void PngPrint (...., int fd, ....)
{
....
      fprintf((FILE *)fd,....
....
}

Surprise!  C does not guarantee that pointer will fit into int and
indeed - this happens to be the case on my Alpha, for example - so if
(FILE *) was passed to a function in 'int' we just lost a significant
chunk of it.  May work accidentally somewhere but it does not make the
code correct.  As a result (not necesarily of the particular piece of
a code above) if I try to look at some 'screenshot' in a graphic
format I am getting a blank screen and maybe a message like this one "
*** Thot: Irrecoverable error ***[1]+ Done(1)".

>From "not seen before" department I notice quite a few instances
of something like " ...if (c == _TABULATION_) ... " where 'c'
is 'char', or maybe 'int'.  The trouble is that from headers
follows that _TABULATION_ is a pointer to a string so a comparison
is not likely to evaluate to "true".

Other than that things seem to work (if one discounts occasional
complaints about "unaligned access" or crashes).

  Regards,
  Michal
  michal@harddata.com

Received on Wednesday, 29 December 1999 13:22:14 UTC