bugFreeciv - Bugs: bug #20881, winsock error 10053...

 
 
Show feedback again

bug #20881: winsock error 10053 (WSAECONNABORTED)

Submitted by:  None
Submitted on:  Sun 09 Jun 2013 11:49:46 AM UTC  
 
Category: generalSeverity: 3 - Normal
Priority: 5 - NormalStatus: Fixed
Assigned to: Marko Lindqvist <cazfi>Originator Email: -unavailable-
Open/Closed: ClosedRelease: 2.3.4
Operating System: Microsoft WindowsPlanned Release: 2.6.0, 3.0.0

Add a New Comment (Rich MarkupRich Markup):
   

You are not logged in

Please log in, so followups can be emailed to you.

 

(Jump to the original submission Jump to the original submission)

Sun 31 Jan 2016 06:50:55 PM UTC, SVN revision 31692:

Added errno mapping for WSAECONNABORTED.

Based on anonymous report.

See bug #20881

(Browse SVN revision 31692)

Marko Lindqvist <cazfi>
Project AdministratorIn charge of this item.
Sun 31 Jan 2016 06:50:49 PM UTC, SVN revision 31691:

Added errno mapping for WSAECONNABORTED.

Based on anonymous report.

See bug #20881

(Browse SVN revision 31691)

Marko Lindqvist <cazfi>
Project AdministratorIn charge of this item.
Wed 27 Jan 2016 03:48:13 AM UTC, comment #7:

- Updated against svn (move of the definitions to new net_types.h)

(file #26495)

Marko Lindqvist <cazfi>
Project AdministratorIn charge of this item.
Fri 22 Jan 2016 06:38:04 AM UTC, comment #6:

> So, for such a common error code as 10053 we should provide
> mapping to errno (ECONNABORTED, I think).


Patch

Not targeting to stable S2_5 as I'm a bit worried (reason why it has taken 2.5 years to make the patch) about the
#undef ECONNABORTED
part. What if ECONNABORTED has a real value before we change it to a synonym of another Winsock specific error value.
The same is of course true for all the error codes that mapping system does, but at least those other mappings have been there "forever" so they are tested not to cause widespread problems.

(file #26409)

Marko Lindqvist <cazfi>
Project AdministratorIn charge of this item.
Fri 14 Jun 2013 09:50:57 AM UTC, comment #5:

I think "missing errno mapping" still has its use: it potentially tells us that bug (that's further in code execution path) is windows specific, and caused by handling of specific errno ignoring same error situation in Windows.

So, for such a common error code as 10053 we should provide mapping to errno (ECONNABORTED, I think).

Marko Lindqvist <cazfi>
Project AdministratorIn charge of this item.
Sun 09 Jun 2013 12:44:36 PM UTC, comment #4:

It's in utility/netintf.c:set_socket_errno() inside #ifdef HAVE_WINSOCK. This translates numeric WSAGetLastError() into a numeric value for the global 'errno' variable, which something distant might later report (intermediate networking code expects Unix errno symbols so it can test for EINTR; these are #defined to Windows equivalents on Windows in netintf.h.)
(Although fc_get_errno() just calls GetLastError() on Windows, and fc_strerror() calls Windows FormatMessage()).)
Perhaps the right thing is just to get rid of the "missing errno mapping" message, since many callers call fc_strerror(fc_get_errno()), which might deliver a textual message? Unless you really needed to call WSAGetLastError().
That's about as far as I got.

Jacob Nevins <jtn>
Project Administrator
Sun 09 Jun 2013 12:22:24 PM UTC, comment #3:

If we just want better error message, it should be simple matter of adding the missing mapping (I can't check just now where we define them, but grepping the "Missing errno mapping" probably gives you default: -case of the switch() containing them)

Marko Lindqvist <cazfi>
Project AdministratorIn charge of this item.
Sun 09 Jun 2013 12:14:26 PM UTC, comment #2:

(This "Missing errno mapping" keeps coming up -- bug #15999, bug #18279, bug #19999 all mention 10053==WSAECONNABORTED. In the two minutes I spent looking at it I couldn't work out what the best way to arrange that it is replaced by "software caused connection abort" through Freeciv's various Winsock-to-Unix-errno mapping machinery, sadly. Not that "software caused connection abort" is a particularly enlightening error message.)

Jacob Nevins <jtn>
Project Administrator
Sun 09 Jun 2013 12:02:34 PM UTC, comment #1:

Winsock error #10053 is "connection aborted": http://support.ipswitch.com/kb/WSK-19980702-EM02.htm

So it seems that server notices one of the client connections got cut from the client side, and server sends error message to remaining local client. Despite error being about connection, it has nothing to do with connection of the client the message is sent to.

Marko Lindqvist <cazfi>
Project AdministratorIn charge of this item.
Sun 09 Jun 2013 11:49:46 AM UTC, original submission:

I got this message in my client "Missing errno mapping for Winsock error #10053. Please, inform about this message to Por favor, informa de este mensaje a http://gna.org/projects/freeciv/"

It was at the same time I disconnected one of the two clients I had opened to perform a short test game.

This is the log:

[13:16:16] Missing errno mapping for Winsock error #10053.
[13:16:16] Por favor, informa de este mensaje a http://gna.org/projects/freeciv/
[13:16:16] Se ha cortado la conexión: ifaesfu2 de System (conexión con retraso) (jugador Rastislav Štefánik).
[13:16:26] Desconectado del servidor.

Anonymous

 

(Note: upload size limit is set to 1024 kB, after insertion of the required escape characters.)

Attach File(s):
   
   
Comment:
   

Attached Files
file #26495:  WSAECONNABORTED-2.patch added by cazfi (1kB - text/x-diff)
file #26409:  WSAECONNABORTED.patch added by cazfi (1023B - text/x-diff)

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -unavailable- added by jtn (Posted a comment)
  • -unavailable- added by cazfi (Posted a comment)
  •  

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 0 encouragements so far.

    Only logged-in users can vote.

     

    Error: not logged in

     

     

    Follow 9 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Sun 31 Jan 2016 06:54:52 PM UTCcazfiStatusReady For Test=>Fixed
      Assigned toNone=>cazfi
      Open/ClosedOpen=>Closed
    Wed 27 Jan 2016 03:48:13 AM UTCcazfiAttached File-=>Added WSAECONNABORTED-2.patch, #26495
    Fri 22 Jan 2016 06:38:21 AM UTCcazfiCategoryclient-gtk-2.0=>general
    Fri 22 Jan 2016 06:38:04 AM UTCcazfiAttached File-=>Added WSAECONNABORTED.patch, #26409
      StatusNone=>Ready For Test
      Planned Release=>2.6.0, 3.0.0
      Summarywinsock error=>winsock error 10053 (WSAECONNABORTED)
    Show feedback again

    Back to the top


    Powered by Savane 3.1-cleanup