[Devel] [ openser-Bugs-1653584 ] lcr broken on big endian platforms

Juha Heinanen jh at tutpro.com
Sat Feb 17 22:46:25 CET 2007


SourceForge.net writes:

 >  1. the openserctl script is assuming little endian for storing the
 >  IP address as an unsigned integer.  This should be fixed by pushing
 >  the proper uint into the database (and adjust the display routine).

i started to work on this so that ip address is stored as string in gw
table.

 >  2. the print_gws() should use ip_addr2a() to print the IP address
 >  3. before using the ip_addr2a(), the host to network translation
 >  must be applied (inside do_load_gws() and print_gws() functions)

this part i don't (at least now) agree to.  lcr code is using openser's
ip_addr2a in many places to convert ip address from internal
representation to string.

if there is a problem with endianity, should ip_addr2a function be fixed
so that it works correctly no matter what endianity the host is?

comments from whoever who considers him/herself responsible of ip_addr2a
function?

-- juha



More information about the Devel mailing list