Results 1 to 2 of 2

Thread: QTcpServer stop listening

  1. #1
    Join Date
    Dec 2011
    Posts
    19
    Qt products
    Qt4
    Platforms
    MacOS X Unix/X11 Windows

    Default QTcpServer stop listening

    Hi,
    I have a QTcpServer listening on port 0xBBBB (lpTcpServer->listen(QHostAddress::Any,0xBBBB)
    When there is the newConnection I need to stop other connctions?
    Is possible to stop the listening (I can't use stop() function because if I stopped its I can't send and receive data).

    Thanks
    Teo

  2. #2
    Join Date
    Jul 2012
    Posts
    40
    Thanks
    12
    Thanked 1 Time in 1 Post
    Qt products
    Qt4
    Platforms
    Unix/X11

    Default Re: QTcpServer stop listening

    Hold your connections in a Qt containter.
    Every Connection has its own socket. And then you can just call socket->disconnect at the serverside....
    Pursue your targets and don't give up....

Similar Threads

  1. QSharedMemory Listening?
    By ManuMies in forum Qt Programming
    Replies: 2
    Last Post: 7th December 2010, 13:42
  2. QTcpServer not listening on S60 Device
    By hasnain in forum Qt for Embedded and Mobile
    Replies: 0
    Last Post: 29th November 2010, 06:27
  3. Listening for a D-Bus signal
    By fabifi in forum Qt Programming
    Replies: 1
    Last Post: 1st February 2009, 10:13
  4. Listening events of a QAxServer module
    By juan in forum Qt Programming
    Replies: 1
    Last Post: 5th February 2008, 14:59
  5. Replies: 1
    Last Post: 18th June 2006, 10:12

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.