[Mingw-users] socklen_t data type

Back to archive index
Pete Linden pete_linde****@att*****
Tue Jun 30 02:47:35 JST 2020


People,

I did not ask about socklen_t data type.  I asked about how to install MinGW so that a stand alone executable can be made.  See below:

I have two installs of Mingw and GFortran.  On the 1st one I can make a Stand Alone Executable using GFortran.  On the 2nd one, I can not make a Stand Alone Executable for GFortran.

Did I make an install error?

Thanks,

Peter N. Linden, P.E.
Linden Professional Services, Inc.
9103 Brahms Lane
Houston, Texas 77040
Direct – 713-937-7875
Cell – 713-253-3216

Peter N. Linden, P.E.
Linden Professional Services, Inc.
9103 Brahms Lane
Houston, Texas 77040
Direct – 713-937-7875
Cell – 713-253-3216

-----Original Message-----
From: MinGW-Users [mailto:mingw****@lists*****] On Behalf Of Eli Zaretskii
Sent: Monday, June 29, 2020 12:10 PM
To: mingw****@lists*****
Subject: [Mingw-users] socklen_t data type

MinGW 5.3.x changed the data type of socklen_t to 'unsigned int' in
ws2tcpip.h (it was 'int' in previous versions).  This causes trouble
when compiling a recent GDB: both Gnulib and GDB's own sources assume
that socklen_t is a signed int.  Moreover, winsock functions like
'accept' and 'getsockname', expect an 'int *' type of their last
argument, and it is customary to pass a 'socklen_t *' value there.

MinGW64 also uses a signed int.

We could of course tell Gnulib, GDB, and the rest of folks to get
their act together and not make such assumptions, but instead add
configure-time tests for the definition of the type and its
signedness.  But is there a good reason for MinGW to make socklen_t an
unsigned data type?  It looks like it's more trouble than help -- if
we want to keep this, we'd need to fight half the world and their dog
to not make the assumptions they do now.

TIA

_______________________________________________
MinGW-Users mailing list
MinGW****@lists*****

This list observes the Etiquette found at
http://www.mingw.org/Mailing_Lists.
We ask that you be polite and do the same.  Disregard for the list etiquette may cause your account to be moderated.

_______________________________________________
You may change your MinGW Account Options or unsubscribe at:
https://lists.osdn.me/mailman/listinfo/mingw-users
Also: mailto:mingw****@lists*****?subject=unsubscribe



More information about the MinGW-Users mailing list
Back to archive index