Skip to content
Tcl Source Code Ticket Change Details
Login

Ticket Change Details

Overview

Artifact ID: 7958a6d529637368def7a141a5872b4bc5a6f691c7af9573faa3c3717bfe377b
Ticket: da0005d2f8b48b031f5899c45d6d2cdcaf1d86e9
tclIO.c:8117:63 incompatible pointer type
User & Date: teclab on 2024-10-26 19:26:48
Changes

  1. assignee changed to: "nobody"
  2. closer changed to: "nobody"
  3. cmimetype changed to: "text/x-fossil-plain"
  4. comment changed to:
    With the new gcc.exe (Rev1, Built by MSYS2 project) 14.2.0 compiling gets an error:
    
    _________________________________
    
    D:/cm/tcltk86/rcompile/tcl/generic/tclIO.c:8117:63: error: passing argument 4 of 'setsockopt' from i
    ncompatible pointer type [-Wincompatible-pointer-types]
     8117 |         setsockopt(tcpData->fds.fd, IPPROTO_TCP, TCP_NODELAY, &newMode, sizeof(newMode));
          |                                                               ^~~~~~~~
          |                                                               |
          |                                                               int *
    In file included from D:/cm/tcltk86/rcompile/tcl/win/tclWinPort.h:51,
                     from D:/cm/tcltk86/rcompile/tcl/generic/tclPort.h:21,
                     from D:/cm/tcltk86/rcompile/tcl/generic/tclInt.h:36,
                     from D:/cm/tcltk86/rcompile/tcl/generic/tclIO.c:15:
    D:/Programs/msys64/mingw64/include/winsock2.h:1035:88: note: expected 'const char *' but argument is
     of type 'int *'
     1035 |   WINSOCK_API_LINKAGE int WSAAPI setsockopt(SOCKET s,int level,int optname,const char *optva
    l,int optlen);
          |                                                                            ~~~~~~~~~~~~^~~~~
    ~
    make: *** [Makefile:625: tclIO.o] Error 1
    
    _________________________________
    
    
    With the old gcc.exe (Rev6, Built by MSYS2 project) 13.2.0 this step passed but with warning:
    
    E:/gitlab-runner/builds/Uyyf6o_gt/0/product/tcltk/rcompile/tcl/generic/tclIO.c:8117:63: warning: passing argument 4 of 'setsockopt' from incompatible pointer type [-Wincompatible-pointer-types]
     8117 |         setsockopt(tcpData->fds.fd, IPPROTO_TCP, TCP_NODELAY, &newMode, sizeof(newMode));
          |                                                               ^~~~~~~~
          |                                                               |
          |                                                               int *
    In file included from E:/gitlab-runner/builds/Uyyf6o_gt/0/product/tcltk/rcompile/tcl/win/tclWinPort.h:51,
                     from E:/gitlab-runner/builds/Uyyf6o_gt/0/product/tcltk/rcompile/tcl/generic/tclPort.h:21,
                     from E:/gitlab-runner/builds/Uyyf6o_gt/0/product/tcltk/rcompile/tcl/generic/tclInt.h:36,
                     from E:/gitlab-runner/builds/Uyyf6o_gt/0/product/tcltk/rcompile/tcl/generic/tclIO.c:15:
    C:/Programs/msys2/mingw64/include/winsock2.h:1035:88: note: expected 'const char *' but argument is of type 'int *'
     1035 |   WINSOCK_API_LINKAGE int WSAAPI setsockopt(SOCKET s,int level,int optname,const char *optval,int optlen);
          |                                                                            ~~~~~~~~~~~~^~~~~~
    
    
    _________________________________
    
    
    
    Thank You!
    
  5. foundin changed to: "core-8-6-branch"
  6. is_private changed to: "0"
  7. login: "teclab"
  8. priority changed to: "5 Medium"
  9. private_contact changed to: "6bac77948ef91492d41f70b5be732fdb60f91282"
  10. resolution changed to: "None"
  11. severity changed to: "Minor"
  12. status changed to: "Open"
  13. submitter changed to: "teclab"
  14. subsystem changed to: "69. Other"
  15. title changed to: "tclIO.c:8117:63 incompatible pointer type"
  16. type changed to: "Bug"