On Nov 12, 2007, at 8:29 AM, Ralf S. Engelschall wrote:
> On Mon, Nov 12, 2007, Jeff Johnson wrote:
>
>> How are you detecting these?
>
> Well, I build RPM with "devtool standalone" on as much *different*
> Unix platforms as possible. The "different" here especially means
> that one needs at least the combinations of 32/64 bit architectures,
> BSD/Linux/Solaris flavors and GCC/Sun/Intel compilers. If one at least
> builds any piece of C code under those max 2x3x3 combinations (or at
> least a fair subset of them) one usually always is able to detect such
> issues.
>
Porting code to as many platforms as possible methodology well known,
always "works".
> Addtionally, I regularily use the commercial FlexeLint tool. This is
> not open source (like the "splint" you are using), but IMHO worth the
> investment as it is really the best C/C++ linter available on the
> market
> since years. A quick run of this tool very often already sheds some
> light on pending code issues.
>
Hmm, thanks for the ptr, added to the X-mas wish list ;-)
Meanwhile, I'll make a pass with splint this week, which should
nail signedness and size problems easily. I've never bothered
using splint for integer issues ...
> These particular issues here for instance popped up when I built under
> an AMD64 platform where the sizes were actually different. On IA32
> platforms the sizes by coincidence matched so you have not seen the
> mismatches yourself, Jeff. I guess you are coding mainly under a IA32
> Fedora platform, right?
>
Yes.
>> [...]
>> I lack a functional methodology ...
>
> No, I guess you just lack the necessary number of *different*
> platforms...
That and the energy to maintain the mess.
(aside) Thanks for the "--> warnings ..." report. I screwed something
there and not looked at --import recently.
As for the segfault, wrapping to avoid the NULL rpmteA return
on gpg-pubkeys is likely overkill. Changing to use rpmteNVRA
(or rpmteNEVRA) consistently likely fixes too. There should be
a ".pubkey" arch generated for arch-less pubkeys on at lease
some of the code paths.
coffee first ...
73 de Jeff
Received on Mon Nov 12 14:50:52 2007