Results 1 to 4 of 4

Thread: Ping and QProcess (exitcode() question)

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,368
    Thanks
    3
    Thanked 5,018 Times in 4,794 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Wiki edits
    10

    Default Re: Ping and QProcess (exitcode() question)

    ping might be requiring a tty.
    Your biological and technological distinctiveness will be added to our own. Resistance is futile.

    Please ask Qt related questions on the forum and not using private messages or visitor messages.


  2. The following user says thank you to wysota for this useful post:

    hakermania (30th August 2011)

  3. #2
    Join Date
    Aug 2011
    Posts
    1
    Thanked 1 Time in 1 Post
    Qt products
    Qt4
    Platforms
    Windows

    Default Re: Ping and QProcess (exitcode() question)

    Try removing "http://" in line 4.

    params << "-c" << "1" << "www.google.com";

    Ping expects an IP or an hostname, "http://" isn't part of the hostname.

  4. The following user says thank you to thalis for this useful post:

    hakermania (30th August 2011)

  5. #3
    Join Date
    Jul 2010
    Location
    /home/hakermania/
    Posts
    233
    Thanks
    129
    Thanked 3 Times in 3 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11

    Default Re: Ping and QProcess (exitcode() question)

    Quote Originally Posted by thalis View Post
    Try removing "http://" in line 4.

    params << "-c" << "1" << "www.google.com";

    Ping expects an IP or an hostname, "http://" isn't part of the hostname.
    good point
    When you 're trying to help somebody in the newbie section, don't forget that he is a newbie. Be specific and give examples.

Similar Threads

  1. Question about QProcess::ExitCode() !
    By jackmack in forum Qt Programming
    Replies: 1
    Last Post: 30th July 2010, 09:38
  2. Replies: 1
    Last Post: 13th November 2008, 10:46
  3. Any body who have a ping soure code using qt ?
    By longtrue in forum Qt Programming
    Replies: 1
    Last Post: 10th March 2008, 11:29
  4. exitCode problem in QProcess
    By mattia in forum Newbie
    Replies: 7
    Last Post: 26th November 2007, 15:09
  5. How to ping a server ?
    By Nyphel in forum Newbie
    Replies: 2
    Last Post: 23rd April 2007, 11:27

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Qt is a trademark of The Qt Company.