zoukankan      html  css  js  c++  java
  • \sdk\include\wspiapi.h(47) : error C2265: '' : reference to a zerosized array is illegal

    编写IP多播程序时,要用到ipmrep结构,在编译时会遇到如下的错误:
    \sdk\include\wspiapi.h(47) : error C2265: '' : reference to a zero-sized array is illegal
    这种错误是由于wspiapi.h头文件里缺少 #define _WSPIAPI
    COUNTOF 语句造成的!
    解决办法是:找到你安装的platformsdk/include目录下的wspiapi.h头文件,开头部分写如这条语句即可:#define WSPIAPICOUNTOF
    源代码如:
    -->原库文件代码:

    ifndef WSPIAPIH_

    define WSPIAPIH_

    include // sprintf()

    include // calloc(), strtoul()

    include // calloc()

    include // strlen(), strcmp(), strstr()

    经过修改后代码:

    ifndef WSPIAPIH_

    define WSPIAPIH_

    // 添加了#define WSPIAPICOUNTOF

    define WSPIAPICOUNTOF

    include // sprintf()

    include // calloc(), strtoul()

    include // calloc()

    include // strlen(), strcmp(), strstr()

      然后重新编译程序即可!
    
    邮箱 tickup [{at}] QQ.COM
  • 相关阅读:
    IPC---信号量
    static的用法
    模拟对话框的实现
    Dom选择器使用与调试记录
    第一个javascript脚本
    javascript基础总汇
    overflow的量两种模式
    固定标签到页面
    固定标签到某个标签
    固定标签(position: fixed)
  • 原文地址:https://www.cnblogs.com/sevensky/p/2282688.html
Copyright © 2011-2022 走看看