New compilation errors building Cygwin DLL

Mark Geisert mark@maxrnd.com
Sun Feb 25 00:28:00 GMT 2018


I'm getting the following two errors building after a recent 'git pull'...

/oss/src/winsup/cygwin/fhandler_socket_unix.cc: In member function 
'virtual int fhandler_socket_unix::ioctl(unsigned int, void*)':
/oss/src/winsup/cygwin/fhandler_socket_unix.cc:589:10: error: 'ret' may be 
used uninitialized in this function [-Werror=maybe-uninitialized]
    return ret;
           ^~~
/oss/src/winsup/cygwin/fhandler_socket_unix.cc: In member function 
'virtual int fhandler_socket_unix::fcntl(int, intptr_t)':
/oss/src/winsup/cygwin/fhandler_socket_unix.cc:607:10: error: 'ret' may be 
used uninitialized in this function [-Werror=maybe-uninitialized]
    return ret;
           ^~~

I'd submit a patch but I'm unsure whether ret needs initialization to 0 or 
to -1 (with appropriate set_errno(EBLAH)).

Thanks,

..mark



More information about the Cygwin-developers mailing list