2009-08-20 Geoff Norton <gnorton@novell.com>
[mono.git] / mcs / class / System / System.Net.Sockets / ChangeLog
1 2009-08-20  Geoff Norton  <gnorton@novell.com>
2
3         * Socket_2_1.cs: Disable ipv6 on monotouch.
4
5 2009-07-14  Sebastien Pouliot  <sebastien@ximian.com>
6
7         * Socket_2_1.cs, SocketAsyncEventArgs.cs: A bit more NET_2_1 defines
8         to help the tuner remove some extra types for moonlight.
9
10 2009-06-28  Gert Driesen  <drieseng@users.sourceforge.net>
11
12         * Socket.cs: Modified some argument names to match MS. Moved disposed
13         check before argument checks in Receive. Use SocketError.InvalidArgument
14         instead of using magic numbers. Added back comments that was
15         accidentally removed in my previous commit.
16         * Socket_2_1.cs: Modified some argument names to match MS.
17
18 2009-06-28  Gert Driesen  <drieseng@users.sourceforge.net>
19
20         * Socket.cs: In GetSocketOption, throw SocketException when (byte [])
21         option value is null. Use SocketError fields instead of using "magic"
22         number. In SetSocketOption (SocketOptionLevel, SocketOptionName, object)
23         only accept Linger, AddMembership, DropMembership and verify option
24         value.
25         * MulticastOption.cs: Added argument checks. Save interfaceIndex that is
26         passed to .ctor, and removed MonoTODO. Renamed arguments to match MS.
27         Reset InterfaceIndex when LocalAddress is modified, and reset
28         LocalAddress when InterfaceIndex is modified.
29         * UdpClient.cs: Modified exception to more closely match MS. Fixed
30         (int, AddressFamily) .ctor to construct IPv6 endpoint when family is
31         InterNetworkV6. Added null check for multicastAddr to (IPAddress)
32         JoinMulticastGroup overload. In (int, IPAddress) and (IPAddress,
33         IPAddress) overloads of JoinMulticastGroup throw SocketException when
34         client is IPv4. Added null check for multicastAddr to (IPAddress, int),
35         overload, and moved JoinMulticastGroup call after argument checks.
36         * IPv6MulticastOption.cs: Renamed argument names to match MS. Added
37         null check to set_Group. Added range check to set_InterfaceIndex.
38
39 2009-06-27 Gonzalo Paniagua Javier <gonzalo@novell.com>
40
41         * Socket.cs: turn WSAEINVAL into ArgumentException.
42
43 2009-06-26 Gonzalo Paniagua Javier <gonzalo@novell.com>
44
45         * Socket.cs: MS throws a SocketException in the byte[] overload when
46         the value is null.
47
48 2009-05-22  Sebastien Pouliot  <sebastien@ximian.com>
49
50         * Socket_2_1.cs: Do not throw a SecurityException if the security
51         policy check fails in NET_2_1 but set the SocketError to AccessDenied
52         ensure the EndPoint has a valid policy before connecting.
53         * SocketAsyncEventArgs.cs: Don't recurse endlessly in SendCallback
54         and ReceiveCallback if the socket is not connected. Check for
55         AccessDenied in ConnectCallback (needed for the security policy
56         check in NET_2_1).
57
58 2009-05-14  Sebastien Pouliot  <sebastien@ximian.com>
59
60         * Socket_2_1.cs: Add ConnectAsync support for NET_2_1 which will
61         ensure the EndPoint has a valid policy before connecting.
62         * SocketAsyncEventArgs.cs: Add support for IList<ArraySegment<byte>>
63         when sending. Add ConnectSocket for NET_2_1
64
65 2009-05-11 Gonzalo Paniagua Javier <gonzalo@novell.com>
66
67         * TcpClient.cs:
68         * Socket.cs:
69         * UdpClient.cs: use GetHostAddresses() instead of Resolve or
70         GetHostEntry.
71
72 2009-05-11 Gonzalo Paniagua Javier <gonzalo@novell.com>
73
74         * UdpClient.cs: if possible, avoid DNS lookups when the host name is
75         an IP address. Related to bug #502866.
76
77 2009-04-30 Gonzalo Paniagua Javier <gonzalo@novell.com>
78
79         * Socket.cs: return the last error if a connect to multiple addresses
80         fails.
81
82 2009-04-22  Sebastien Pouliot  <sebastien@ximian.com>
83
84         * Socket_2_1.cs: Use old-n-simple CheckProtocolSupport to implement
85         OSSupportsIP[v4|v6] for Moonlight (NET_2_1 only) so we can avoid 
86         including a bunch of types (22) from System.Net.NetworkInformation 
87         and drop the number of [SecuritySafeCritical] methods to audit (the 
88         same 22) and [SecurityCritical] (8) beside getting a smaller 
89         System.Net.dll assembly :)
90
91 2009-04-21 Gonzalo Paniagua Javier <gonzalo@novell.com>
92
93         * Socket.cs: End* methods can only be called once per IAsyncResult.
94         Bug #466031 fixed.
95
96 2009-04-09  Sebastien Pouliot  <sebastien@ximian.com>
97
98         * Socket.cs: Split socket class into two files (this one and the
99         new Socket_2_1.cs). This let us remove (some) existing #if in the
100         sources and avoid (a lot) of new ones for Moonlight.
101         * Socket_2_1.cs: Just enough of socket for NET_2_1. This helps
102         the tuner not to bring a lot of extra stuff (some visible)
103         into Moonlight.
104         * SocketAsyncEventArgs.cs: Ifdef out some cases for NET_2_1 so 
105         Moonlight can use it's own (smaller) SocketAsyncOperation enum
106
107 2009-02-17 Gonzalo Paniagua Javier <gonzalo@novell.com>
108
109         * Socket.cs: instead of clearing the sockets form the output and then
110         adding them back, we just remove the ones that have not been signaled.
111         Fixes bug #354090 and bug #476138.
112
113 2009-01-19 Gonzalo Paniagua Javier <gonzalo@novell.com>
114
115         * Socket.cs: don't throw when there's no ipv6 configuration.
116
117 2009-01-09  Dick Porter  <dick@ximian.com>
118
119         * Socket.cs: Special case 0-length receive requests in the
120         BeginAccept overloads that wait for data, so they behave as the
121         non-waiting version.  Seems to match MS behaviour, fixes bug
122         464201.
123
124 2009-01-06 Gonzalo Paniagua Javier <gonzalo@novell.com>
125
126         * TcpClient.cs: use IPv6Any when the family is IPv6.
127         Bug #462688 fixed.
128
129 2008-12-30  Bill Holmes  <billholmes54@gmail.com>
130
131         * Socket.cs (Accept_internal) :  Changing the signature to pass 
132           the blocking state.
133
134         Code is contributed under MIT/X11 license.
135
136 2008-12-20  Miguel de Icaza  <miguel@novell.com>
137
138         * SocketException.cs: Add missing API.
139
140         * SocketAsyncEventArgs.cs (Dispose): this has to be a public
141         member according to the specs.
142
143 2008-12-20 Gonzalo Paniagua Javier <gonzalo@novell.com>
144
145         * Socket.cs: add a new ReceiveFrom_nocheck that does not throw an
146         exception in case of error.
147
148 2008-12-20 Gonzalo Paniagua Javier <gonzalo@novell.com>
149
150         * Socket.cs: if Blocking is set, translate a WouldBlock into a
151         TimedOut.
152
153 2008-12-03 Gonzalo Paniagua Javier <gonzalo@novell.com>
154
155         * UdpClient.cs: don't Poll() in Receive(), the call to ReceiveFrom
156         will block anyway. Fixes bug #455894.
157
158 2008-11-12 Gonzalo Paniagua Javier <gonzalo@novell.com>
159
160         * Socket.cs: mark the socket as not connected when there is a pending
161         error or exception about to be thrown.
162         Bug #443346 fixed.
163
164 2008-09-10  Bill Holmes  <billholmes54@gmail.com>
165
166         * Socket.cs : Adding a comment to provide locations where
167           changes to MonoSocketAsyncResult need to be synced.
168
169         Code is contributed under MIT/X11 license.
170
171 2008-09-06  Atsushi Enomoto  <atsushi@ximian.com>
172
173         * Socket.cs : (SocketAsyncResult) release byte buffer early so that
174           it does not have to store extra data in pool. Fixed bug #397627.
175
176 2008-07-31  Jb Evain  <jbevain@novell.com>
177
178         * Socket.cs
179         * NetworkStream.cs: cleanup for NET_2_1
180
181         * SocketException_2_1.cs: new specific version for NET_2_1.
182
183 2008-06-19  Dick Porter  <dick@ximian.com>
184
185         * Socket.cs: Implement generic Send() and Receive() methods.
186         Fixes bug 395168.
187
188 2008-06-12  Stephane Delcroix  <sdelcroix@novell.com>
189
190         * Socket.cs: minimal changes to run in the 2.1 profile
191
192 2008-06-11  Stephane Delcroix  <sdelcroix@novell.com>
193
194         * SocketAsyncEventArgs.cs: catch SocketException in ConnectAsync
195         and set the SocketError accordingly.
196
197 2008-05-09  Marek Habersack  <mhabersack@novell.com>
198
199         * SocketAsyncEventArgs.cs: implemented support for executing
200         asynchronous socket actions, called from the new xxxxAsync methods
201         in Socket. The asynchronous operations do not use the ThreadPool
202         as I can't get the sample applications to work (send/receive
203         callbacks don't work) - it may change in the future.
204
205         * Socket.cs: implemented several xxxxAsync 2.0sp1 methods. The
206         ones not implemented for now are: ReceiveMessageFromAsync and
207         SendPacketsAsync. AcceptAsync doesn't perform the check for the
208         buffer size for now - need to implement runtime support for that.
209         Made several methods internal, so that they can be accessed from
210         SocketAsyncEventArgs code.
211
212 2008-05-08  Marek Habersack  <mhabersack@novell.com>
213
214         * SocketAsyncOperation.cs, SendPacketsElement.cs,
215         SocketAsyncEventArgs.cs: added initial implementations for
216         2.0SP1/3.5 classes used in the (to be implemented) new xxxAsync
217         methods of the Socket class.
218
219 2008-04-17  Miguel de Icaza  <miguel@novell.com>
220
221         * NetworkStream.cs: Throw an IOException if the socket is not
222         connected, not an ArgumentException.   
223
224         Fixes #371923, it is also the way its documented on MSDN. 
225
226 2008-04-13  Jb Evain  <jbevain@novell.com>
227
228         * Socket.cs: ifdef out the Sys.Config part for the
229         2.1 profile.
230         Merged from the Moonlight 2 branch.
231
232 Wed Mar 12 20:06:07 CET 2008 Paolo Molaro <lupus@ximian.com>
233
234         * Socket.cs: add a static ctor so that ipv4Supported and ipv6Supported
235         are initialized (they are used by the runtime).
236
237 2008-02-01  Dick Porter  <dick@ximian.com>
238
239         * TcpClient.cs: If the Connect fails (when given an array of
240         addresses) leave the socket object in a usable state.  Fixes bug
241         355473.
242
243 2007-11-13  Atsushi Enomoto  <atsushi@ximian.com>
244
245         * NetworkStream.cs : in 2.0 Close() is not needed and does not exist.
246
247 2007-11-01  Miguel de Icaza  <miguel@novell.com>
248
249         * Socket.cs: Do not set the Send and Receive buffer sizes for the
250         socket to the defaults set on Windows, they kill our performance.
251
252         Thanks to Zoltan Varga for tracking the performance issue down.
253         The bug was #325032
254
255 2007-10-30  Dick Porter  <dick@ximian.com>
256
257         * UdpClient.cs: Don't set the multicast option twice.  Fixes bug
258         324033.
259
260 2007-10-21  Robert Jordan  <robertj@gmx.net>
261
262         * Socket.cs: Remove GetHashCode override from the NET_2_0
263         profile. Add LAMESPEC comment. Fixes bug #325113.
264
265 2007-09-22  Gert Driesen  <drieseng@users.sourceforge.net>
266
267         * Socket.cs: Removed unused method.
268
269 2007-08-02  Dick Porter  <dick@ximian.com>
270
271         * Socket.cs: Patch from Brian Nickel (brian.nickel@gmail.com) to
272         improve EndPoint handling.
273
274 2007-07-08  Gert Driesen  <drieseng@users.sourceforge.net>
275
276         * Socket.cs: Code formatting. Marked not implemented methods as TODO.
277         Removed extra spaces.
278
279 2007-07-04  Dick Porter  <dick@ximian.com>
280
281         * Socket.cs: Don't set DontFragment by default for IPv6 sockets.
282         Fixes bug 81985.
283
284 2007-05-16 Adar Wesley <adarw@mainsoft.com>
285
286         * Socket.jvm.cs: added missing methods EndDisconnect, IOControl,
287         Send 2.0 overloads, Receive 2.0 overloads, ReceiveMessageFrom,
288         BeginReceiveMessageFrom, EndReceiveMessageFrom, 
289         EndAccept 2.0 overloads, BeginSend, EndSend, BeginReceive, 
290         EndReceive, SendFile, BeginSendFile, EndSendFile, Disconnect,
291         DuplicateAndClose
292
293 2007-05-09 Igor Zelmanovich <igorz@mainsoft.com>
294
295         * Socket.jvm.cs: Handle property throws NotImplementedException.        
296
297 2007-05-09 Igor Zelmanovich <igorz@mainsoft.com>
298
299         * NetworkStream.cs:
300         * TcpClient.cs:
301         * TcpListener.cs:
302         * UdpClient.cs:                 
303         added MonoNotSupported attribute for TARGATE_JVM.       
304                 
305 2007-03-11  Gert Driesen  <drieseng@users.sourceforge.net>
306
307         * TcpClient.cs: Do not initialize network stream in Connect. In
308         Dispose, only nullify client if network stream was not obtained.
309         Fixes bug #81105.
310
311 2007-01-30  Ilya Kharmatsky <ilyak -at- mainsoft.com>
312
313         * Socket.jvm.cs: additional stubs for net_2_0 properties,
314         bug fixes (EnsureStillUsable method inserted)
315
316 2007-01-28  Ilya Kharmatsky <ilyak -at- mainsoft.com>
317
318         * Socket.jvm.cs: added stubs for net_2_0 properties and methods.
319
320 2007-01-26  Dick Porter  <dick@ximian.com>
321
322         * Socket.cs: SupportsIPv6 is obsolete in the 2.0 profile.  Stub
323         out BeginReceiveMessageFrom(), BeginSendFile(),
324         EndReceiveMessageFrom(), EndSendFile(), ReceiveMessageFrom(), and
325         SendFile().
326
327         * IPPacketInformation.cs: New in the 2.0 profile
328
329         * SocketFlags.cs: Remove useless (and empty) inline documentation,
330         and add 2.0 items.
331
332         * TcpListener.cs: Mark Server as public in the 2.0 profile.
333
334         * UdpClient.cs: Mark Dispose(bool) as protected in the 2.0
335         profile.
336
337         System.Net.Sockets should now be 2.0-complete.
338
339 2007-01-26  Dick Porter  <dick@ximian.com>
340
341         * Socket.cs: There's no point checking the SO_ERROR status of a
342         socket after poll() or select() if we already know that connected
343         == true.
344
345 2007-01-24  Dick Porter  <dick@ximian.com>
346
347         * IOControlCode.cs: 
348         * SocketInformationOptions.cs: 
349         * TransmitFileOptions.cs: Fix enum values
350
351         * AddressFamily.cs: Not Serializable in the 2.0 profile
352
353 2007-01-24  Dick Porter  <dick@ximian.com>
354
355         * NetworkStream.cs: 2.0 profile updates, based on a patch by
356         Sridhar Kulkarni (sridharkulkarni@gmail.com)
357
358 2007-01-23  Dick Porter  <dick@ximian.com>
359
360         * TcpListener.cs: 
361         * TcpClient.cs: 2.0 profile updates, based on a patch by Sridhar
362         Kulkarni (sridharkulkarni@gmail.com)
363
364 2007-01-22  Miguel de Icaza  <miguel@novell.com>
365
366         * Socket.cs: Move the throw new NotImplementedException ()
367         elsewhere to prevent Moma reports.
368
369 2007-01-20  Dick Porter  <dick@ximian.com>
370
371         * Socket.cs(SocketDefaults): Catch and ignore any SocketExceptions
372         thrown from setting default socket options - some platforms might
373         not support a particular default we're trying to set.
374
375 2007-01-11  Dick Porter  <dick@ximian.com>
376
377         * IOControlCode.cs: 
378         * SocketInformation.cs: 
379         * Socket.cs: 
380         * UdpClient.cs: 2.0 profile updates, loosely based on a patch by
381         Sridhar Kulkarni.
382
383         * SocketInformationOptions.cs: 
384         * TransmitFileOptions.cs: Implemented by Sridhar Kulkarni
385         (sridharkulkarni@gmail.com)
386
387 Wed Dec 13 12:04:02 CET 2006 Paolo Molaro <lupus@ximian.com>
388
389         * Socket.cs: stub ReceiveBufferSize and SendBufferSize to
390         get ironpython to compile.
391
392 2006-11-23  Dick Porter  <dick@ximian.com>
393
394         * Socket.cs: Only set Connected = true in Poll() and Select() if
395         the socket error status is 0.  Fixes bug 79878.
396
397 2006-09-28 Andrew Skiba <andrews@mainsoft.com>
398
399         * Socket.cs,NetworkStream.cs,SocketException.cs: TARGET_JVM
400
401 2006-09-11 Gonzalo Paniagua Javier <gonzalo@ximian.com>
402
403         * Socket.cs: update the SocketOperation enum.
404
405 2006-08-16 Gonzalo Paniagua Javier <gonzalo@ximian.com>
406
407         * Socket.cs: replace hardcoded error numbers with the SocketError
408         values. When ReceiveTimeout is set on a blocking socket, correctly
409         report timeouts in the generated exception.
410         
411         * SocketException.cs: add new internal ctor (int, string).
412
413 2006-08-12  Miguel de Icaza  <miguel@novell.com>
414
415         * Socket.cs (NoDelay): Implement.
416
417 2006-06-30 Gonzalo Paniagua Javier <gonzalo@ximian.com>
418
419         * Socket.cs: patch from Sanghyeon Seo that implements
420         (Send|Receive)Timeout for 2.0.
421         * MulticastOption.cs: more 2.0 stuff.
422
423 2006-06-28  Atsushi Enomoto  <atsushi@ximian.com>
424
425         * Socket.cs : use ConfigurationManager.GetSection() under NET_2_0.
426           Also make sure to avoid NRE.
427
428 2006-06-24  Zoltan Varga  <vargaz@gmail.com>
429
430         * Socket.cs: Add stubs for net 2.0 SendTimeout and ReceiveTimeout properties.
431
432 2006-06-20  Zoltan Varga  <vargaz@gmail.com>
433
434         * ProtocolType.cs SocketOptionName.cs: Add missing net 2.0 fields.
435
436 2006-05-30  Gert Driesen  <drieseng@users.sourceforge.net>
437
438         * NetworkStream.cs: Marked Dispose (bool) virtual on 1.x profile.
439
440 2006-04-10  Gonzalo Paniagua Javier <gonzalo@ximian.com>
441
442         * Socket.cs:
443         * SocketError.cs: implemented Reseive/Send overloads that do not throw
444         in case of error. Patch by Tomi Valkeinen.
445
446 2006-03-11  Miguel de Icaza  <miguel@novell.com>
447
448         * NetworkStream.cs (Dispose): Use the right signature depending on
449         the profile being built.
450
451 2006-03-09 Gonzalo Paniagua Javier <gonzalo@ximian.com>
452
453         * Socket.cs: pass something not empty to the unixep ctor.
454
455 2006-03-03  Dick Porter  <dick@ximian.com>
456
457         * UdpClient.cs: Fix IPv6 family check.  Fixes bug 77689.
458
459 2006-02-23 Gonzalo Paniagua Javier <gonzalo@ximian.com>
460
461         * TcpClient.cs: when the socket is not connected, don't try to set the
462         socket options, as they are ignored on linux. Wait until Connect
463         succeeds and then apply the options.
464
465 2006-02-03 Gonzalo Paniagua Javier <gonzalo@ximian.com>
466
467         * Socket.cs: added a missing overload for SetSocketOption.
468
469 2006-01-19 Gonzalo Paniagua Javier <gonzalo@ximian.com>
470
471         * Socket.cs: use the 2.0 configuration classes when checking for IPv6
472         support.
473
474 2006-01-04  Sebastien Pouliot  <sebastien@ximian.com>
475
476         * TcpClient.cs: The Client property is public in 2.0 while it was
477         protected in earlier release. Fix bug #77048.
478
479 2005-12-07  Robert Jordan  <robertj@gmx.net>
480
481         * SocketError.cs: Added.
482         * SocketException: Implemented SocketErrorCode. Fixes bug #76915.
483
484 2005-10-11  Dick Porter  <dick@ximian.com>
485
486         * Socket.cs: Don't call connect(2) twice for non-blocking sockets,
487         it breaks on macos (and probably other bsd-based stacks too,) use
488         poll() and getsockopt() to check if it worked.
489
490 2005-09-27 Gonzalo Paniagua Javier <gonzalo@ximian.com>
491
492         * Socket.cs: add checks for 'disposed' all over. Fixes bug #76249.
493
494 2005-06-07 Gonzalo Paniagua Javier <gonzalo@ximian.com>
495
496         * TcpClient.cs: patch by Hans Kratz that uses an integer when setting
497         NoDelay instead of a bool, which is only handled in 2.0.
498
499 2005-06-04 Gonzalo Paniagua Javier <gonzalo@ximian.com>
500
501         * Socket.cs: disallow connecting to .Any addresses. Fixes bug #75154.
502
503 2005-06-01 Gonzalo Paniagua Javier <gonzalo@ximian.com>
504
505         * Socket.cs: adapted Select to the new Select_internal that uses poll()
506         instead of select(). Managed part of the fix for bug #71203.
507
508 2005-05-23 Gonzalo Paniagua Javier <gonzalo@ximian.com>
509
510         * Socket.cs: apply the same hack on blocking Connect calls as the one
511         used in Accept.
512
513 2005-05-07 Gonzalo Paniagua Javier <gonzalo@ximian.com>
514
515         * Socket.cs: see bug #74842, which is fixed with this patch for details
516         and test cases on the blocking behavior of accept() when close() is
517         called from another thread. The solution applied is to Abort the thread
518         that is blocking in Accept_internal() when someone calls Close (), then
519         reset the abort state if the socket is disposed and return the same
520         error as MS (10004 - interrupted).
521
522 2005-05-06 Gonzalo Paniagua Javier <gonzalo@ximian.com>
523
524         * Socket.cs: match MS behavior on SetSocketOption with a boolean
525         argument. MS 1.1 throws an ArgumentException, but 2.0 turns true/false
526         into 1/0 and works fine. Fixes bug #71753. Added checks for disposed
527         in the 3 SetSocketOption.
528
529 2005-05-03 Gonzalo Paniagua Javier <gonzalo@ximian.com>
530
531         * Socket.cs: if there are outstanding aio requests and one of them gets
532         an ObjectDisposedException, throw the same exception for the rest.
533
534 2005-05-02 Gonzalo Paniagua Javier <gonzalo@ximian.com>
535
536         * Socket.cs: removed hack added to fix bug #53229 (more than a year ago)
537         that kept sockets opened until all AIO operations where finished. If
538         the socket is closed, Receive returns 0 in EndReceive, the rest throw
539         the ObjectDisposedException. Set the socket handle to -1 when closing.
540
541 2005-04-18 Gonzalo Paniagua Javier <gonzalo@ximian.com>
542
543         * Socket.cs: Begin/End Send/SendTo guarantee that all bytes are written
544         or an exception is thrown. Fixes bug #74475.
545
546 2005-04-17 Gonzalo Paniagua Javier <gonzalo@ximian.com>
547
548         * Socket.cs: no need for locking in Worker. The actual read / write for
549         Receive / Send is performed in the runtime time.
550
551 2005-04-15 Gonzalo Paniagua Javier <gonzalo@ximian.com>
552
553         * Socket.cs: added a 'blocking' field that is passed to the runtime.
554
555 2005-04-09 Gonzalo Paniagua Javier <gonzalo@ximian.com>
556
557         * Socket.cs: invoke the callback after scheduling the next request for
558         the socket. Fixes bug #74539.
559
560 2005-04-08 Gonzalo Paniagua Javier <gonzalo@ximian.com>
561
562         * Socket.cs: update socket connected status in an async request finishes
563         synchronously. Use 'callback' instead of 'real_callback' field, which is
564         now unused.
565
566 2005-04-07 Gonzalo Paniagua Javier <gonzalo@ximian.com>
567
568         * Socket.cs: added SocketOperation enum and 2 new fields to
569         SocketAsyncResult that are used by the runtime. Asynchronous read/write
570         are serialized so that only 1 of each kind is really 'active'.
571         Handle non-blocking connects in BeginConnect instead of doing 2 Poll()
572         in the threadpool.
573
574         * NetworkStream.cs: better message for the exception.
575
576 2005-04-04 Gonzalo Paniagua Javier <gonzalo@ximian.com>
577
578         * Socket.cs: remove unused async IO code.
579
580 2005-03-01 Gonzalo Paniagua Javier <gonzalo@ximian.com>
581
582         * Socket.cs: don't Poll/block in Connect aither.
583
584 2005-02-28 Gonzalo Paniagua Javier <gonzalo@ximian.com>
585
586         * Socket.cs: don't block on Accept if the socket is non-blocking.
587         Fixes bug #73053. Patch by Ankit Jain.
588
589 2005-02-23  Dick Porter  <dick@ximian.com>
590
591         * UdpClient.cs: Set the Broadcast option, as apparently the MS
592         runtime defaults make UDP sockets broadcastable.
593
594 2004-12-28 Gonzalo Paniagua Javier <gonzalo@ximian.com>
595
596         * Socket.cs: for Receive*/Send*, don't set the connected status to false
597         when the error is EINPROGRESS or EWOULDBLOCK.
598
599 2004-12-03 Gonzalo Paniagua Javier <gonzalo@ximian.com>
600
601         * NetworkStream.cs: Write should ensure that writes all the contents
602         of the buffer. Fixes bug #70123. Besos para Miguelito.
603
604 2004-10-14  Dick Porter  <dick@ximian.com>
605
606         * Socket.cs (Sockets ): Set Accept()ed socket blocking status to
607         be the same as the listening socket.  This follows MS behaviour.
608
609 2004-08-04  Dick Porter  <dick@ximian.com>
610
611         * Socket.cs: Update Connected state in Select and Poll; this is
612         when we find out that non-blocking Connects succeed.  Fixes bug
613         62398.
614
615 2004-07-28  Dick Porter  <dick@ximian.com>
616
617         * Socket.cs: ReceiveFrom might not return a valid EndPoint.  Patch
618         by Nick Vaughan (dev@6wardlaw.freeserve.co.uk), fixes bug 61608.
619
620 2004-07-15  Dick Porter  <dick@ximian.com>
621
622         * Socket.cs: Don't try and dereference a null array in Select()
623         (possible if a descriptor list of length 0 was passed.)  Patch by
624         Nick Vaughan (dev@6wardlaw.freeserve.co.uk), fixes bug 61595.
625
626 2004-07-12 Gonzalo Paniagua Javier <gonzalo@ximian.com>
627
628         * Socket.cs: if'ed RemoveReferences calls.
629
630 2004-07-09  Dick Porter  <dick@ximian.com>
631
632         * Socket.cs: Slight tweak to allow unknown objects to be returned
633         by GetSocketOption().
634
635 2004-06-28 Gonzalo Paniagua Javier <gonzalo@ximian.com>
636
637         * Socket.cs: connect on non-blocking sockets returns EINPROGRESS. Fixes
638         bug #60811.
639
640 2004-06-23 Gonzalo Paniagua Javier <gonzalo@ximian.com>
641
642         * Socket.cs: wrong error code in connect and accept. EWOULDBLOCK is
643         10035. Fixes bug #60563.
644
645 2004-06-20  Gonzalo Paniagua Javier <gonzalo@ximian.com>
646
647         * Socket.cs: fixed Accept for non-blocking sockets.
648
649 2004-06-10  Gert Driesen <drieseng@users.sourceforge.net>
650
651         * LingerOption.cs: marked field private to fix API signature
652         * MulticastOption.cs: marked field private to fix API signature
653
654 2004-06-05  Gonzalo Paniagua Javier <gonzalo@ximian.com>
655
656         * Socket.cs: throw ArgumentNullException if all the list are null OR
657         empty. Fixes bug #59632.
658
659 2004-05-21  Patrik Torstensson <totte@hiddenpeaks.com>
660
661         * TcpListener.cs: Fixes a lot of the problems with remoting nunit tests.
662         
663         (AcceptTcpClient): Don't create TcpClient before a
664         connection is accepted.
665         
666         (LocalEndPoint): Use Server LocalEndPoint if connected
667         otherwise use endpoint from ctor.
668         
669         (Init): Save end point, not server endpoint. This did
670         cause TcpListener to ignore port sent via constructor.
671
672         (Pending): Fixed wait time (method should return directly)
673         
674         (Start): Moved Bind here instead of Init method; old method
675         caused us to bind ports even if the listener was stopped.
676         
677         (Stop): Null server when stopping
678
679 2004-05-13  Dick Porter  <dick@ximian.com>
680
681         * UdpClient.cs: 
682         * TcpClient.cs: Public API fixes
683
684 2004-05-07  Gonzalo Paniagua Javier <gonzalo@ximian.com>
685
686         * Socket.cs: fixed Connect for non-blocking sockets. Closes bug #58169.
687
688 2004-05-03  Gonzalo Paniagua Javier <gonzalo@ximian.com>
689
690         * Socket.cs: fix for BeginConnect and non-blocking sockets.
691
692 2004-05-03  Lluis Sanchez Gual <lluis@ximian.com>
693
694         * Socket.cs: Use assembly name const to load Mono.Posix.
695
696 2004-05-01  Gonzalo Paniagua Javier <gonzalo@ximian.com>
697
698         * Socket.cs: only enable socket AIO if MONO_ENABLE_SOCKET_AIO is there.
699         I will remove this once THE bug is hunted.
700
701 2004-04-28  Gonzalo Paniagua Javier <gonzalo@ximian.com>
702
703         * Socket.cs: added support for unmanaged asynchronous IO. Speed up
704         error checking.
705         * UdpClient.cs: fixed Dispose so that it only closes the socket when
706         called explicitly.
707
708 2004-04-24  Gonzalo Paniagua Javier <gonzalo@ximian.com>
709
710         * Socket.cs: added GetSupportsAsync and Poll_internal internal calls.
711         Cleaned up Worker class: moved fields to SocketAsyncResult and use Poll
712         when the socket is non-blocking before getting EWOULDBLOCK error.
713
714 2004-04-08  Dick Porter  <dick@ximian.com>
715
716         * Socket.cs: Rearrange the internal calls so that the exceptions
717         are thrown from managed code
718
719 2004-03-21  Gonzalo Paniagua Javier <gonzalo@ximian.com>
720
721         * Socket.cs: when Dispose (bool) is called from the finalizer, always
722         do the cleanup. Fixes yet another nullref with xsp.
723
724 2004-02-19  Gonzalo Paniagua Javier <gonzalo@ximian.com>
725
726         * Socket.cs: implemented IOControl.
727
728 2004-02-18  Gonzalo Paniagua Javier <gonzalo@ximian.com>
729
730         * Socket.cs: use the threadpool for asynchronous calls instead of
731         creating new threads.
732
733 2004-02-12  Gonzalo Paniagua Javier <gonzalo@ximian.com>
734
735         * Socket.cs: added locks around waithandle assign and comparison in
736         class Worker. Handle other exceptions than SocketException for
737         non-blocking sockets.
738
739 2004-01-24  Gonzalo Paniagua Javier <gonzalo@ximian.com>
740
741         * Socket.cs: handle WSAEWOULDBLOCK for non-blocking sockets. Fixes
742         bug #53168. Avoid the creation of the ManualResetEvent in class Worker
743         whenever possible.
744
745 2004-01-24  Gonzalo Paniagua Javier <gonzalo@ximian.com>
746
747         * Socket.cs: if we have a pending async event, delay socket closing
748         until EndX is called. Fixes bug #53229. Check parameters and if the
749         socket has been disposed. Implemented IDisposable explicitly. The
750         threads created have IsBackground = true now.
751
752 2004-01-10  Gonzalo Paniagua Javier <gonzalo@ximian.com>
753
754         * Socket.cs: patch from Brad Fitzpatrick <brad@danga.com> episode 2.
755
756 2003-12-30  Gonzalo Paniagua Javier <gonzalo@ximian.com>
757
758         * Socket.cs: fix for several asynchronous methods to delay exception
759         throwing.  Patch by Brad Fitzpatrick <brad@danga.com>.
760
761 2003-12-18  Gonzalo Paniagua Javier <gonzalo@ximian.com>
762
763         * TcpListener.cs: get the LocalEndPoint from the socket after binding.
764         Fixes bug #52329.
765
766 2003-10-20  Miguel de Icaza  <miguel@ximian.com>
767
768         * TcpClient.cs: Fix void Dispose (bool disposing) to follow the
769         pattern.  It was shutting down the managed resources even in the
770         finalizer case, it should only do that when called from
771         IDisposable.Dipose.
772
773 2003-09-11  Lluis Sanchez Gual <lluis@ximian.com>
774
775         * NetworkStream.cs: Added [In,Out] attributes to Read method.
776
777 2003-08-24  Gonzalo Paniagua Javier <gonzalo@ximian.com>
778
779         * TcpListener.cs: various fixes to make the new tests pass. Closes
780         bug #47848.
781
782 2003-08-10  Miguel de Icaza  <miguel@ximian.com>
783
784         * UdpClient.cs (Receive): Fix Bug 45633;  We should do a blocking
785         call until a datagram is arrives from the remote host.  This
786         removes the 512 "magic" buffer size when we did not have any data.
787  
788 2003-07-31  Gonzalo Paniagua Javier <gonzalo@ximian.com>
789
790         * NetworkStream.cs:
791         * Socket.cs: fixed array boundary checks. 0 sized arrays are allowed.
792
793 2003-07-18  Andreas Nahr <ClassDevelopment@A-SoftTech.com>
794
795         * Socket.cs: Added GetHashCode method
796
797 2003-07-14  Jerome Laban <jlaban@wanadoo.fr>
798
799         * Socket.cs:
800         * ProtocolType.cs:
801         * SocketOptionLevel.cs:
802         * TcpListener.cs:
803         * TcpClient.cs:
804         * UdpClient.cs:
805         
806         Added IPv6 support.
807
808         * IPv6MulticastOption.cs: Added for IPv6 support.
809
810 2003-05-16  Dick Porter  <dick@ximian.com>
811
812         * Socket.cs: Use Mono.Posix.UnixEndPoint if its available
813
814 2003-05-11  Gonzalo Paniagua Javier <gonzalo@ximian.com>
815
816         * MulticastOption.cs: patch by Jerome Laban included in bug #42393.
817
818 2003-05-05  Gonzalo Paniagua Javier <gonzalo@ximian.com>
819
820         * Socket.cs:
821         (Select): don't create arrays if not needed.
822         (Poll): call Select_internal directly.
823
824         Warning: you need an up to date runtime for this to work!
825
826 2003-03-25  Gonzalo Paniagua Javier <gonzalo@ximian.com>
827
828         * UdpClient.cs: don't bind the socket unless .ctor (IPEndPoint) is used.
829         Added more checks and throws.
830         Small fixes in Send to avoid duplicating the buffer.
831         Moved CheckIfDisposed calls to the start of the methods instead of doing
832         the check inside a finally clause.
833
834 2003-03-03  Gonzalo Paniagua Javier <gonzalo@ximian.com>
835
836         * Socket.cs:
837         (SendTo): fix from Jerome Laban <jlaban@wanadoo.fr>.
838
839 2003-02-28  Gonzalo Paniagua Javier <gonzalo@ximian.com>
840
841         * Socket.cs: patch from Elan Feingold <efeingold@mn.rr.com>. Fixes
842         NullReferenceException when the callback is null.
843
844 2003-02-17  Gonzalo Paniagua Javier <gonzalo@ximian.com>
845
846         * NetworkStream.cs: allow 0 size array in Write.
847
848 2003-02-16  Gonzalo Paniagua Javier <gonzalo@ximian.com>
849
850         * Socket.cs: make Worker.Connect and Receive work with non-blocking
851         sockets. May be Receive* and Send* in Worker need to do the same. I'll
852         wait for bug reports. Set IsCompleted to true before invoking the end
853         callback. Fixes bug #38136.
854
855 2003-01-23  Gonzalo Paniagua Javier <gonzalo@ximian.com>
856
857         * NetworkStream.cs: the check for disposed should not be done in the
858         finally clause.
859
860 2003-01-04  Gonzalo Paniagua Javier <gonzalo@ximian.com>
861
862         * UdpClient.cs: fixed bug #36226.
863
864 2002-11-13  Dick Porter  <dick@ximian.com>
865
866         * Socket.cs: Only close the socket in one place, ie the Dispose
867         method.  Fixes bug 32054.
868
869 2002-11-09  Gonzalo Paniagua Javier <gonzalo@ximian.com>
870
871         * Socket.cs: offset == size == 0 it's ok in Send ().
872
873 2002-11-03  Phillip Pearson  <pp@myelin.co.nz>
874
875         * TcpClient.cs: Fixed SetTcpClient() to pass through to the Client 
876         property, which now sets stream to null (it's set by GetStream()).  This 
877         should make GetStream() work on a TcpClient which has had the socket set 
878         by assignment to the Client property, not only one that has been created 
879         by TcpListener.AcceptTcpClient().
880
881 2002-10-08  Dick Porter  <dick@ximian.com>
882
883         * Socket.cs: 
884         * NetworkStream.cs: Bounds checking fixes, and better exception
885         texts.  Changes by timothyjmills@hotmail.com (Timothy J. Mills).
886
887 2002-10-03  Dick Porter  <dick@ximian.com>
888
889         * TcpClient.cs: NoDelay is a TCP option, not Socket
890
891 2002-09-16  Miguel de Icaza  <miguel@ximian.com>
892
893         * SocketFlags.cs: Add missing enumeration.
894
895         * UdpClient.cs: Make Dispose private.
896
897 2002-08-20  Dick Porter  <dick@ximian.com>
898
899         * Socket.cs: Fix deadlock when the AsyncResult callback calls
900         End*().  Set the async request's worker property so it can return
901         results.  These two fixes combined fix bug 28092.
902
903 2002-06-24  Dick Porter  <dick@ximian.com>
904
905         * Socket.cs: Make SetSocketOption cope with boolean values (they
906         are passed as objects, not the ints the runtime was expecting)
907
908 2002-05-17  Lawrence Pit <loz@cable.a2000.nl>
909         * TcpListener.cs: Renamed LocalEndPoint to LocalEndpoint
910         * NetworkStream.cs, UdpClient.cs and TcpClient.cs: modified disposable 
911         routines, added checks for disposed state.
912         * UdpClient.cs: commented out GetHashCode and Equals as it's not
913         overriden in ms.net implementation.
914
915 2002-05-17  Jaroslaw Kowalski <jarek@atm.com.pl>
916         * TcpClient.cs: fixed SetTcpClient so that
917         TcpListener.AcceptTcpClient works and allows
918         you to call GetStream() on its result
919
920 2002-04-24  Dick Porter  <dick@ximian.com>
921
922         * Socket.cs (Poll): Give correct argument to Select(), as spotted
923         by Jaroslaw Kowalski <jarek@atm.com.pl>
924
925 2002-04-16  Gonzalo Paniagua Javier <gonzalo@ximian.com>
926
927         * UdpClient.cs: implemented.
928
929 2002-04-02  Dick Porter  <dick@ximian.com>
930
931         * TcpListener.cs: in Start(), set the socket listen backlog value
932         to a sane value (noticed by Jonathan Stowe <gellyfish@gellyfish.com>)
933
934 2002-02-13  Dick Porter  <dick@ximian.com>
935
936         * Socket.cs: Implemenent Select, Blocking, Connected,
937         GetSocketOption, Poll, SetSocketOption and Shutdown
938
939         * MulticastOption.cs: 
940         * LingerOption.cs: Delete override methods that don't need to be
941         implemented
942
943 2002-01-23  Miguel de Icaza  <miguel@ximian.com>
944
945         * NetworkStream.cs: Implement class.
946
947 2002-01-23  Dick Porter  <dick@ximian.com>
948
949         * SocketException.cs: Implemented
950
951         * Socket.cs: Implemented most methods
952
953         * LingerOption.cs: Made compile
954
955         * AddressFamily.cs: Removed empty auto-generated comments
956
957 2002-01-17  Miguel de Icaza  <miguel@ximian.com>
958
959         * SocketException.cs: Reimplemented.
960
961 2002-01-06  Ravi Pratap  <ravi@ximian.com>
962
963         * ChangeLog : Add to this directory.
964
965         * SocketException.cs, TcpClient.cs, TcpListener.cs : MonoTODO
966         attribute decoration.