Results 1 to 3 of 3

Thread: qapplication with open(/dev/name,O_RDWR) crashed???

  1. #1
    Join Date
    Sep 2006
    Posts
    1
    Qt products
    Qt3 Qt/Embedded
    Platforms
    MacOS X Unix/X11 Windows

    Red face qapplication with open(/dev/name,O_RDWR) crashed???

    //my demo program
    main(argc,argv)
    {
    QApplication a(argc,argv);
    int fp = open("/dev/devname",O_RDWR);
    //open err
    }
    //
    main(argc,argv)
    {
    int fp = open("/dev/devname",O_RDWR);
    QApplication a(argc,argv);
    //open() is correct, but QApplication a(argc,argv) cannot stop;
    }

    any body can help me????

  2. #2
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    5,372
    Thanks
    28
    Thanked 976 Times in 912 Posts
    Qt products
    Qt3 Qt4
    Platforms
    Unix/X11 Windows

    Default Re: qapplication with open(/dev/name,O_RDWR) crashed???

    Maybe Qt also tries to open that device?

  3. #3
    Join Date
    Jan 2006
    Location
    Gold Coast, Australia
    Posts
    36
    Thanked 5 Times in 5 Posts
    Qt products
    Qt5 Qt/Embedded
    Platforms
    MacOS X Unix/X11 Windows Android

    Default Re: qapplication with open(/dev/name,O_RDWR) crashed???

    Might try

    Qt Code:
    1. int fp = ::open("/dev/devname",O_RDWR);
    To copy to clipboard, switch view to plain text mode 
    Freelance Senior Software Engineer

Similar Threads

  1. QApplication: no such file or directory
    By jochen_r in forum Newbie
    Replies: 13
    Last Post: 15th November 2008, 21:46
  2. Replies: 15
    Last Post: 21st April 2007, 17:46
  3. Reponsabilities of QApplication and QMainWindow classes
    By yellowmat in forum Qt Programming
    Replies: 4
    Last Post: 4th September 2006, 16:21
  4. Can I create a QApplication inside a DLL?
    By oob2 in forum Qt Programming
    Replies: 6
    Last Post: 1st July 2006, 10:08
  5. subclassing QApplication
    By nupul in forum Newbie
    Replies: 2
    Last Post: 19th April 2006, 19:29

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.