-
Notifications
You must be signed in to change notification settings - Fork 63
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Crash when loading consecutive images quickly #94
Comments
Confirmed:
At first, I though it might be related to Qt 5.9 but the Qt image viewer I've made for my personal use doesn't show this symptom. |
You're right, it's not a Qt 5.9.0 bug since I can reproduce this on Qt 5.8.0 too. Can be a Qt 5.x.x bug though :D |
No, the bug is lximage-qt. I'll look into it whenever I find some free time. |
This is a race condition accessing the Disconnecting the diff --git a/src/mainwindow.cpp b/src/mainwindow.cpp
index 16191d9..f6e7c6f 100644
--- a/src/mainwindow.cpp
+++ b/src/mainwindow.cpp
@@ -583,7 +584,9 @@ void MainWindow::updateUI() {
void MainWindow::loadImage(const Fm::FilePath & filePath, QModelIndex index) {
// cancel loading of current image
if(loadJob_) {
+ disconnect(loadJob_, &Fm::Job::finished, this, &MainWindow::onImageLoaded);
loadJob_->cancel(); // the job object will be freed automatically later
loadJob_ = nullptr;
}
if(imageModified_) { Maybe |
reopening... as the solution wasn't approved and merged into master yet |
If you open an image from a folder that has other images, lximage-qt crashes if you pass quickly to the next/previous pressing keyboard right/left. It's even easier when quickly scrolling up/down with mouse wheel.
The text was updated successfully, but these errors were encountered: