Modify

Opened 12 years ago

Closed 12 years ago

Last modified 12 years ago

#2253 closed Bug (Fixed)

Ping returns success with no connection

Reported by: vacko Owned by: trancexx
Milestone: 3.3.9.5 Component: AutoIt
Version: 3.3.8.1 Severity: None
Keywords: Ping Cc:

Description

If you boot your OS with LAN cable unplugged and use ping function

$result = Ping("8.8.8.8", 1000)
MsgBox(262144,'Result','Return Value is: ' & $result & @lf & @lf & '@error code is: ' & @error )

return value will be 1 and @error will be 0
but corect return value should be 0 and @error should be 4 (or 1).
I think this is not correct.

I duplicated this issue under Windows 7, WinPE 3.0, WinPE 4.0

Attachments (0)

Change History (11)

comment:1 Changed 12 years ago by trancexx

  • Resolution set to No Bug
  • Status changed from new to closed

Any other thoughts you like to share?

comment:2 Changed 12 years ago by Manfred.kurth@…

I can't believe you close it - spent around 2h today because of this malfunction :-(

Developed with XP-SP3 all working properly. Then, 2008R2-64 _without_ connected network, ping always comes back with 1 and @error=0. I made a test with Win_7-32-Professional, the same issue.

I have to supervise a connection by a cyclic ping to the remote-machine, to log the times and send out an alarm if broken. Broken can be the wide-are-line, but also a switch without power. I can trash my development, thank you!

If this is not a bug, remove 'Ping' from AutoIT.

comment:3 follow-ups: Changed 12 years ago by trancexx

This is not bug the way you described it, that's why it's closed as no bug.
Your LAN cable plug_in state is irrelevant unless you are connected to machine at 8.8.8.8 throug it.
You probably wanted to say "I have no internet connecion and Ping() returns success for Google server". Is that what you are saying?
If yes then I'll reword your report, reopen it, fix it and close it again. In any case much more work than it should be done.
Ok?

comment:4 in reply to: ↑ 3 Changed 12 years ago by Manfred.Kurth@…

Replying to trancexx:

Sorry, the first entry was not from me!. I had a look because of my problem and found it, seems to be the similar.

Your LAN cable plug_in state is irrelevant unless you are connected to machine at 8.8.8.8 throug it.

I'm not connected because the cable ist not in!

You probably wanted to say "I have no internet connecion and Ping() returns success for Google server". Is that what you are saying?

Over the day, between my normal work, I made some short tests with 2008R2 im my lab-environment.

I start up the Machine, but it has no physical network-connection. I try some Ping in the cmd-window, always timeout / no answer, OK.

Starting my AutoIT "Ping (10.19.55.10)" and the answer ist 1 - error=0, wrong!

I restart the pc again, instead of a disconnected cable a small local switch without any further connection - the same, 1 / error 0 even if the destination is not reachable.

In the moment I cannot find out all circumstances where it fails, but seems to be an interaction with Windows'-network-startup-condition.

I have no idea, how to program a sure workaround :-(

I hope, in the evening I can make the exactly same tests with XP.

Best regards
Manfred

comment:5 Changed 12 years ago by trancexx

  • Summary changed from Ping return wrong return value if you boot your OS with LAN cable unlugged to Ping returns success with no connection

comment:6 Changed 12 years ago by trancexx

  • Resolution No Bug deleted
  • Status changed from closed to reopened

comment:7 Changed 12 years ago by trancexx

  • Milestone set to 3.3.9.5
  • Owner set to trancexx
  • Resolution set to Fixed
  • Status changed from reopened to closed

Fixed by revision [7205] in version: 3.3.9.5

comment:8 in reply to: ↑ 3 Changed 12 years ago by manfred.kurth@…

Hello trancexx -

many thanks you tried to fix. I made a new test using 3.3.9.5 on 2008R2-64 - not succesfull.

Looking a little bit deeper, I found a second dependency: If the network-card is configured to use DHCP, but because of the broken cable or also the not responding DHCP-server no IP is assigned to, ping also comes back with 1 / error=0. I didn't check with Win_7 because I feel sure, it's the same.

So the test must be:

1.) NIC configured to use DHCP, no alternative IP-configuration, power up the PC with no cable connected.

2.) Power up the PC with cable connected only to a local switch, but no DHCP is responding.

If the network was running before, it seems to work - so always we have to come up from the switched off computer!

A few minutes before I tested the same with XP-SP3 - starting up with DHCP no responding and / or no cable, Ping always comes back with 0 and Error 2 or Error 3 - properly.

Please look again, or should I better request a new ticket?

comment:9 Changed 12 years ago by guinness

That version is Alpha and doesn't even contain the fix trancexx made.

comment:10 Changed 12 years ago by Valik

Stop wasting our time, please. I've just deleted your other ticket. In case it wasn't clear: YOU DO NOT HAVE ACCESS TO A VERSION OF AUTOIT WITH THE FIX.

comment:11 Changed 12 years ago by AdmiralAlkex

That's hilarious. Testing for a 4 day old fix on a product that was released closer to 5 months ago.

Does not compute.

Guidelines for posting comments:

  • You cannot re-open a ticket but you may still leave a comment if you have additional information to add.
  • In-depth discussions should take place on the forum.

For more information see the full version of the ticket guidelines here.

Add Comment

Modify Ticket

Action
as closed The owner will remain trancexx.
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.