[Mono-bugs] [Bug 333723] System.Net.NetworkInformation. Ping work only in asynchrone mode

bugzilla_noreply at novell.com bugzilla_noreply at novell.com
Sun Oct 14 17:23:32 EDT 2007


https://bugzilla.novell.com/show_bug.cgi?id=333723#c2





--- Comment #2 from Eric Petit <surfzoid2002 at yahoo.fr>  2007-10-14 15:23:31 MST ---
In fact i say something wrong, the both test cases work if you use a DNS, like
"google.com", but fail if you use a ip like "192.168.0.10"(one of my local
Ip's)

[root at surfzoidPC Debug]# mono ./PingExample.exe google.com
Time to live: 64
Don't fragment: True
ping status: Success
Address: 72.14.207.99
RoundTrip time: 156
Time to live: 64
Don't fragment: True
Buffer size: 32
Ping example completed.
[root at surfzoidPC Debug]# mono ./PingExample.exe 192.168.0.33
Time to live: 64
Don't fragment: True
Ping failed:
System.NotSupportedException: Unexpected socket error during ping request:
WouldBlock
  at System.Net.NetworkInformation.Ping.Send (System.Net.IPAddress address,
Int32 timeout, System.Byte[] buffer, System.Net.NetworkInformation.PingOptions
options) [0x00000]
  at
System.Net.NetworkInformation.Ping+<>c__CompilerGenerated11.<SendAsync>c__37
(System.Object o, System.ComponentModel.DoWorkEventArgs ea) [0x00000]
Ping example completed.
[root at surfzoidPC Debug]# mono ./PingExample.exe 192.168.0.10
Time to live: 64
Don't fragment: True
Ping failed:
System.NotSupportedException: Unexpected pair of ICMP message type and code:
type is 8 and code is 0
  at System.Net.NetworkInformation.Ping+IcmpMessage.get_IPStatus () [0x00000]
  at System.Net.NetworkInformation.Ping.Send (System.Net.IPAddress address,
Int32 timeout, System.Byte[] buffer, System.Net.NetworkInformation.PingOptions
options) [0x00000]
  at
System.Net.NetworkInformation.Ping+<>c__CompilerGenerated11.<SendAsync>c__37
(System.Object o, System.ComponentModel.DoWorkEventArgs ea) [0x00000]
Ping example completed.
[root at surfzoidPC Debug]#    


-- 
Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.


More information about the mono-bugs mailing list