[Verse-dev] Verse Bug

Emil Brink emil at obsession.se
Mon Oct 22 12:00:34 CEST 2007


On 10/6/07, Cervantes Pintor Pedro <pedrocp at lycos.com> wrote:
> I'm having a very serious bug in Verse
>
> The problem is that apparently verse doesn't handle well the endianness, and
> this leads to a series of problems like apparently not getting the geometry
> on Connector and wrong display in materials, etc. and of course applications
> using verse on heterogeneous networks works erratically.

Whoa. I think this is slightly exaggerated, since I'm pretty confident
that Verse's endianness-handling for packing/unpacking data to/from
the network is pretty okay. You seem to have detected a bug, but that
doesn't mean that the endianness as a whole is mishandled.

[...]
> Investigating a little more I saw that the real64 numbers has Words
> inverted, say that the real64 is composed of two 4 byte words, then the
> first word should be really the second, and the second should be the first.
> Like:
>
> A = 4 byte word
> B = 4 byte word
> real64 = AB and when this is uploaded to the server and then sent to a
> different client it gets real64 = BA !!
>
> Is the community aware of this?

I was not aware of this, no. I'm very sorry for the problem, which is
of course something that should have been detected earlier. I believe
that since all the active developers close to me, when I was working
on Verse, used x86, we didn't trigger the problem. We used various
platforms (Linux, Windows, Mac), but the underlying hardware was the
same so it didn't cause any issues.

It might be that the fix for this is trivial; I have not had the time
to look into it and am reluctant to say that I will. But the file is
v_pack.c in the Verse codebase, the functions are
vnp_raw_pack_real64() and vnp_raw_unpack_real64(). They sure look
suspicious after a quick inspection.

Regards,

/Emil


More information about the Verse-dev mailing list