title: Retrieving ping host name from SendPingAsync result
body: <p>I'm pinging hosts from list of strings (addresses). Everything works perfectly but when host is unreachable ping returns <code>Result.Address</code>: "0.0.0.0" instead of existing address or hostname which I passed into SendPingAsync function.
  Here is my code:</p>
  
  <pre><code>            var pingTasks = addresses.Select(address =&gt;
              {
                  return new Ping().SendPingAsync(address);
              });
  
              await Task.WhenAll(pingTasks);
  
              StringBuilder pingResultBuilder = new StringBuilder();
  
              foreach (var pingReply in pingTasks)
              {
                  pingResultBuilder.Append(pingReply.Result.Address);
                  pingResultBuilder.Append("    ");
  
                  pingResultBuilder.Append(pingReply.Result.Status);
                  pingResultBuilder.Append("    ");
  
                  pingResultBuilder.Append(pingReply.Result.RoundtripTime.ToString());
                  pingResultBuilder.AppendLine();
              }
  
              Console.WriteLine(pingResultBuilder.ToString());
  </code></pre>
  
  <p>I found solution <a href="https://stackoverflow.com/questions/6602845/ping-sendasync-returned-replay-from-0-0-0-0-how-to-get-pinged-address">here</a> but I need to do the same thing in <code>SendPingAsync</code> function instead of <code>SendAsync</code>.
  How can I retrieve passed <code>host name / ip address</code> from <code>pingReply.Result</code>?</p>