[Pkg-jed-sl-modules] [ths@networkno.de: About alpha/mipsel FTBFS of slcfitsio]

Rafael Laboissiere rafael at debian.org
Sat Nov 19 17:06:54 UTC 2005


Hi Thiemo,

Thanks for your message.  I am forwarding it to the upstream author of
the slcfitsio module.

Please, send followups to pkg-jed-sl-modules, which is the appropriate
mailing list for discussing about the S-Lang modules.

Cheers,

-- 
Rafael

----- Forwarded message from Thiemo Seufer <ths at networkno.de> -----

From: Thiemo Seufer <ths at networkno.de>
Subject: About alpha/mipsel FTBFS of slcfitsio
Date: Fri, 18 Nov 2005 13:39:09 +0100
To: pkg-jed-devel at lists.alioth.debian.org

Hello All,

I think the runtime error is caused by the byte swapping in
src/cfitsio-module.c. The byte_swap*() functions try to swap in-place.
write_tbit_col() provides an dynamic buffer and copies the data first,
but read_bit_column() doesn't, which means it tries to change read-only
data on little endian machines.

This fails for little endian architectures which keep such data in
read-only sections of their object format, for other little endian
machines it is a (probably hidden) bug as soon as the data is read
a second time, because it would get swapped back to the wrong endianess
then.

The solution is to either add a intermediate buffer in read_bit_column()
or to change the swap functions to do a swap-and-copy to a different
place. The latter is more efficient in some cases.


Thiemo

_______________________________________________
Pkg-jed-devel mailing list
Pkg-jed-devel at lists.alioth.debian.org
http://lists.alioth.debian.org/mailman/listinfo/pkg-jed-devel



----- End forwarded message -----

-- 
Rafael



More information about the Pkg-jed-sl-modules mailing list