You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
The reason will be displayed to describe this comment to others. Learn more.
I had to revert this in 445675a because the method is intentionally called with invalid proxyIndex (for root). I don't see any problem in this method because it is legal to call rowCount() and index() with invalid index and item pointer is checked.
Was it really crashing in this method? Maybe it was crashing the next time qgis was started and browser tried to expand paths? Can you post backtrace?
9837f43
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I had to revert this in 445675a because the method is intentionally called with invalid proxyIndex (for root). I don't see any problem in this method because it is legal to call rowCount() and index() with invalid index and item pointer is checked.
Was it really crashing in this method? Maybe it was crashing the next time qgis was started and browser tried to expand paths? Can you post backtrace?
9837f43
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi @blazek,
The app crashes on startup. Here is the related bits of the trace:
I substituted the following (to check if the index's internal pointer is not 0 instead) and it avoids the startup crash:
Does that work out OK for your implementation, instead?
9837f43
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
internalPointer() won't help because invalid index has null internalPointer().
It seems however that hideEvent() is called before showEvent() on Mac. mModel and mProxyModel are created in showEvent(). I added checks in 4fde34a.
9837f43
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@blazek I can confirm here that 4fde34a does fix the startup crash. Thanks!