fix #10340: properly handle EINVAL on OSX and also avoid to call handle_connect() in case of a disconnetected socket which is not meant to connect.
diff --git a/Misc/NEWS b/Misc/NEWS
index 81c3740..02bafcd 100644
--- a/Misc/NEWS
+++ b/Misc/NEWS
@@ -34,6 +34,10 @@
 Library
 -------
 
+- Issue #10340: asyncore - properly handle EINVAL in dispatcher constructor on
+  OSX; avoid to call handle_connect in case of a disconnected socket which
+  was not meant to connect.
+
 - Issue #14204: The ssl module now has support for the Next Protocol
   Negotiation extension, if available in the underlying OpenSSL library.
   Patch by Colin Marc.