#4 Broken heap when compiled with MSVC

open
nobody
None
5
2007-02-16
2007-02-16
Anonymous
No

Problems in intf-win32.c:

1. Heap is broken when libdnet 1.11 compiled on MSVC (Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 14.00.50727.762 for 80x86) after call any of folow functions:

intf_get
intf_get_src
intf_get_dst
intf_loop

2. Function snprintf not exists in MSVC headers, so we must use _snprintf.

3. Constant MIB_IF_TYPE_MAX defined as 32, but must be equal to MAX_IF_TYPE from ipifcons.h

Solution:

Apply this patch

Discussion

  • Pach for intf_* API for WIN32

     
    Attachments
  • Logged In: NO

    Patch submitted by Rush, please contact me if you want to create MSVC project for libdnet rush dog rush dot nov dot ru