Menu

#852 use correct IPv4 address sizes and return types

closed
None
5
2012-11-08
2007-08-30
No

Various tables in mibII used sometimes wrong ipv4 address size (sizeof(unsigned long)) and mostly the ipv4 addresses were returned in unsigned long*, which is working on little endian 64 bit platform (e.g. intel x86_64), but does not work on big endian (e.g. ppc64).

I have rewritten these parts to return in_addr_t *, which should always work.

Applies to latest SVN, tested on Fedora 7 Linux (x86_64).

Discussion

  • Jan Safranek

    Jan Safranek - 2007-08-30
     
  • Wes Hardaker

    Wes Hardaker - 2008-02-13

    Logged In: YES
    user_id=76242
    Originator: NO

    Thanks for the patch! It has been applied to the 5.3.x and 5.4.x code branches and the main development tree, and will appear in future releases of the Net-SNMP package.

     
  • Thomas Anders

    Thomas Anders - 2008-02-14

    Logged In: YES
    user_id=848638
    Originator: NO

    There's a typo in the patch (as applied in r16799) that breaks the build on quite a few systems.
    Fixed in r16806.

     

Log in to post a comment.