|
From: | Sergio Gelato |
Subject: | [Gnu-arch-users] tla 1.3.3 bugfixes |
Date: | Tue, 23 Aug 2005 19:09:28 -0000 |
User-agent: | Mutt/1.5.9i |
This may be anticlimactic in the current context, but here are the patches I've needed to apply to tla 1.3.3 in order to make it work on Solaris with the Sun Studio 9 compiler. Maybe they'll save someone else some work. Patch 1: [hackerlab] add a _dummy member to struct obtable_elt, since zero-sized structs are not allowed in C99. See the final committee draft's paragraph 6.2.5[#19]: "A structure type describes a sequentially allocated *nonempty* set of member objects". Patch 2: [hackerlab] elt is of type void*, so sizeof(*elt) is sizeof(void), which is not defined. Patch 3: [hackerlab] a void function shouldn't try to return a value. Patch 4: the compiler complained about type incompatibility, probably because rel_record_nil has the const attribute but rel_table._r doesn't. I don't know who is right, but the workaround was straightforward. Patch 5: this is the biggie. Fixes multiple segmentation faults in the test suite. The main problem is that the code uses an integer 0 to terminate the argument list to rel_add_records, but that function treats its arguments (including the terminator) as having type rel_record, which is a structure type and therefore not assignment-compatible with 0. My patch switches to using rel_record_nil as the argument list terminator. In passing I found one place in src/tla/libarch/libraries.c where the terminator was missing entirely (look at the fourth hunk for that file, starting on line 122). Patch 6: this is the only patch that was already in my set for 1.2.1pre1. Trivial typo in one of the test scripts. I'm amazed that it wasn't caught sooner.
tla-1.3.3-1.diff
Description: Text document
tla-1.3.3-2.diff
Description: Text document
tla-1.3.3-3.diff
Description: Text document
tla-1.3.3-5.diff
Description: Text document
tla-1.3.3-6.diff
Description: Text document
tla-1.3.3-7.diff
Description: Text document
[Prev in Thread] | Current Thread | [Next in Thread] |