Menu

#6 amd64 bugfix

closed-accepted
nobody
None
5
2010-06-11
2009-04-23
Oliver Hitz
No

On my amd64 platform, the tool produced invalid files with partially random content due to incorrect data types. This patch fixes this problem and applies some configure and Makefile fixes that makes the tool compile cleanly.

Tested on Debian 5.0 (amd64) and Debian Unstable (686).

Discussion

  • Oliver Hitz

    Oliver Hitz - 2009-04-23

    amd64 patch

     
  • Richard Laager

    Richard Laager - 2010-06-11

    I'm taking over the abandoned docsis project. The code is available on http://github.com/rlaager/docsis.

    Going through your patch, here are my comments:

    configure, src/Makefile.in: These are generated files, so I ignored these changes.

    configure.in: I had already fixed the GNU m4 issue in a very similar, but slightly simpler way, so I ignored that change.
    configure.in, src/Makefile.am: I had also already fixed the -lm issue, but your fix is correct, so I replaced my fix with yours.

    src/docsis_common.h: This is the start of a big set of changes that renames intval and uintval to longval and ulongval, respectively. However, you didn't change the underlying type of those variables. For this reason, I ignoed all of these changes. (I won't mention them again, since there's a lot.) If you really meant to change the type, please let me know. I don't see why that type would need to be changed. Also, in docsis_snmp.c, you changed some sizeof(int)s to sizeof(long)s. This seems wrong given that the underlying type is still int.

    src/docsis_decode.c, src/docsis_decode.h: The change in decode_unknown should really be a change to size_t, so I did that instead. I accepted the snprintf_hexadecimal change.

    src/docsis_snmp.c, src/docsis_snmp.h: I accepted the cast changes. I had already made the exact same size_t changes.

    src/md5.c, src/md5.h: It seemed easier to change the UINT typedefs than to change all the uses of them, so I accepted those changes from https://sourceforge.net/tracker/?func=detail&aid=2789622&group_id=22615&atid=375631 instead.

    I hope to cut a 0.9.6 release soon, ideally today. Thanks for the patch!

     
  • Richard Laager

    Richard Laager - 2010-06-11
    • status: open --> closed-accepted
     
  • Richard Laager

    Richard Laager - 2010-06-12

    I stand corrected. The sizeof(long) changes were required. I made the changes in a slightly different way. Thanks for the patch!

     

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.