Results 1 to 7 of 7

Thread: QFileDialog Crashes with Networked Drive

  1. #1
    Join Date
    Jan 2006
    Location
    Third rock from the sun
    Posts
    106
    Thanks
    17
    Thanked 6 Times in 6 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Unhappy QFileDialog Crashes with Networked Drive

    I am using (both as a subclass and directly) a QFileDialog to open files, keeping track of the last directory opened and subsequently setting the last directory each time the dialog opens using setDirectory( ). Everything works fine until after the user goes into a network mounted drive (I am using Windows XP btw). If the user traverses into the directory, everything is fine, but if I try to setDirectory directly to the network drive path, the application crashes with an invalid Heap pointer error. It seems to crash because of the length of time it takes to access the drive. The crash also occurs if I quickly double click on the network drive immediately after the dialog opens. Is there some fix out there for this? Or am I stuck with a crashing application?

    I am using Qt 4.3.0 on Visual Studios 2005.

    Thanks!!

  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: QFileDialog Crashes with Networked Drive

    Sounds familiar. Have you checked the task tracker and changelogs for 4.3 releases?

  3. #3
    Join Date
    Jan 2006
    Location
    Third rock from the sun
    Posts
    106
    Thanks
    17
    Thanked 6 Times in 6 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Re: QFileDialog Crashes with Networked Drive

    It seems that there is a "similar" bug: Task ID 193483 involving hidden directories and Task ID 195192 involving always accessing network drives. Only the one with the hidden directories mentions crashes, but the code example
    Qt Code:
    1. #include <QtGui/QtGui>
    2.  
    3. int main(int argc, char *argv[])
    4. {
    5. QApplication a(argc, argv);
    6. // d.setDirectory(QDir::homePath() + "/.kde/share"); // works
    7. d.setDirectory(".foo/bar");
    8. d.exec();
    9. }
    To copy to clipboard, switch view to plain text mode 
    is essentially what I am doing in Windows. It says the hidden directories is "fixed" in 4.3.4, does anyone know if this fix works for network mounted drives in Windows as well? I dont want to roll to 4.3.4 at this point in the game unless it will fix this issue. Maybe in combination with the slow network drive access this is a problem, but I find it hard to believe I am the first person to try and setDirectory to a network drive.

  4. #4
    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: QFileDialog Crashes with Networked Drive

    Quote Originally Posted by Rayven View Post
    Maybe in combination with the slow network drive access this is a problem, but I find it hard to believe I am the first person to try and setDirectory to a network drive.
    Maybe it's some incarnation of this bug: QFileDialog crashes when forward slash // on Windows?

    I would create a small application that reproduces the problem and try it on the newest Qt 4.3 version.

  5. #5
    Join Date
    Jan 2006
    Location
    Third rock from the sun
    Posts
    106
    Thanks
    17
    Thanked 6 Times in 6 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Re: QFileDialog Crashes with Networked Drive

    Quote Originally Posted by jacek View Post
    Maybe it's some incarnation of this bug: QFileDialog crashes when forward slash // on Windows?

    I would create a small application that reproduces the problem and try it on the newest Qt 4.3 version.
    I will once I get the "ok" to download and install it...dont ask...long story! I will post results once I get them.

  6. #6
    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: QFileDialog Crashes with Networked Drive

    Quote Originally Posted by Rayven View Post
    I will once I get the "ok" to download and install it...dont ask...long story! I will post results once I get them.
    Then maybe it will be faster to contact the Trolls ask them about the bug?

  7. #7
    Join Date
    Jan 2006
    Location
    Third rock from the sun
    Posts
    106
    Thanks
    17
    Thanked 6 Times in 6 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default [SOLVED] QFileDialog Crashes with Networked Drive

    Ok I got Qt 4.3.3 installed and it fixed the issue with the QFileDialog crashing. Glad to see the Trolls are on top of things!! Now if they can just get drive names to appear in the QFileDialog all will be super!

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.