On Mon, 2008-12-01 at 01:51 +0100, Markus Kittenberger wrote: > > Removing ntohl() will break the code on little endian > machines. > > sure, somehow i lost this call during rewriting this lines multiple > times,.. )-; > > i should have looked into my diff myself (-; > > so thanks for doing it for me, Alina! > > > Obviously there is a "big usage";-) > > im meant shifting 32 bits of a 32 bit data type is not very useful, as > it makes no sense, because you can just use > x=0 instead of using (and failing) x =x<<32; Yes, but one needs an extra-if(). But - as a software guy - I'm used to workaround - ahemm - inconvenient hardware problems and restrictions. > but sure, obviously it would be better if x << 32 would be 0 instead > of x (-; :-) > > ---- snip ---- > > Fixed an embarrassing bug if we want to generate a netmask from a prefix == 0. > > Added an inline function to avoid someone else making the same mistake > > > All credits belong to Markus Kittenberger > for finding, > > reporting and hunting it down to the root cause. > > ---- snip ---- > > muchas gratias, for the credits and for the inline function, ..(-; De nada. I consider another wording of "I tested it and it works now as expected.". And only people hunting down strange and rare bugs know that the real fix is usually just the tip of the iceberg. Bernd -- Firmix Software GmbH http://www.firmix.at/ mobil: +43 664 4416156 fax: +43 1 7890849-55 Embedded Linux Development and Services