Results 1 to 2 of 2

Thread: Control-C to interrupt is not working

  1. #1

    Default Control-C to interrupt is not working

    My program will not respond to a ctrl-c interrupt to terminate it's execution. I have my guesses but not really sure why. The program has no GUI but it utilizes signals/slots so I have a QApplication object to get to a "main loop." I have different app which does put up a "main window" and it responds just fine to the ctrl-C. Is the lack of a window the problem?

    Here is the main:

    Qt Code:
    1. int main (int argc, char *argv[])
    2. {
    3. QApplication a(argc,argv);
    4. ProcessMsgOperation pmo;
    5. return a.exec;
    6. }
    To copy to clipboard, switch view to plain text mode 

    The ProcessMsgOperation sets up some socket connections and a timer. Either when a socket msg or a timer event occurs it reads from a database and then posts a message to a socket.

    Thanks,
    Rick

    Linux or HPUX 11.11
    QT3.3.4
    Threads

  2. #2

    Default Re: Control-C to interrupt is not working

    I have found out that the issue is really the connection to the Oracle DB. I'm using the qt db object and apparently as long as there is an open connection then SIGINT is ignored. This is not strctly speaking a qt issue, from what I can tell this is the way Oracle intends it to work. Based on what I have read it looks like you can register a signal handler with Oracle to handler the SIGINT.

    Is there anyway to do this via some qt object?

    Rick

Similar Threads

  1. Replies: 6
    Last Post: 3rd February 2006, 09:48

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
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.