Crash after pressing ctrl+s in file view #69495

Closed
opened 2019-09-04 15:33:40 +02:00 by Marcin Twarowski · 9 comments

System Information
Operating system: Windows-10-10.0.16299 64 Bits
Graphics card: GeForce GTX 1080/PCIe/SSE2 NVIDIA Corporation 4.5.0 NVIDIA 436.15

Blender Version
Broken: version: 2.81 (sub 5), branch: master, commit date: 2019-09-04 00:01, hash: da25aca267

Exact steps for others to reproduce the error
It happens with new files that are not saved yet.

  • Create new scene.
  • Open file view ("File > Open")
  • Press ctrl+s
  • You can see that the button has changed from open to "Save Blender File":
    obraz.png
  • Now all it takes is to press that button or to press "Cancel" to crash Blender.

Similarly, Blender crashes in "save" window.

  • Create new scene.
  • Open save menu ("File > Save")
  • Press ctrl+s
  • Now all it takes to crash Blender is to press any of the two buttons.
**System Information** Operating system: Windows-10-10.0.16299 64 Bits Graphics card: GeForce GTX 1080/PCIe/SSE2 NVIDIA Corporation 4.5.0 NVIDIA 436.15 **Blender Version** Broken: version: 2.81 (sub 5), branch: master, commit date: 2019-09-04 00:01, hash: `da25aca267` **Exact steps for others to reproduce the error** It happens with new files that are not saved yet. - Create new scene. - Open file view ("File > Open") - Press ctrl+s - You can see that the button has changed from open to "Save Blender File": ![obraz.png](https://archive.blender.org/developer/F7716344/obraz.png) - Now all it takes is to press that button or to press "Cancel" to crash Blender. Similarly, Blender crashes in "save" window. - Create new scene. - Open save menu ("File > Save") - Press ctrl+s - Now all it takes to crash Blender is to press any of the two buttons.

Added subscriber: @MarcinTwarowski

Added subscriber: @MarcinTwarowski

Added subscriber: @tomjk

Added subscriber: @tomjk

You can also ctrl+o, ctrl+s, ctrl+o to cause this (or ctrl+s, ctrl+o, ctrl+s).

If I run from desktop, the file browser window closes, blender hangs and maxes out a cpu core until killed.

If I run from terminal with --debug-all it will crash immediately with

Memoryblock wmEvent: double free
Aborted
You can also `ctrl+o, ctrl+s, ctrl+o` to cause this (or `ctrl+s, ctrl+o, ctrl+s`). If I run from desktop, the file browser window closes, blender hangs and maxes out a cpu core until killed. If I run from terminal with `--debug-all` it will crash immediately with ``` Memoryblock wmEvent: double free Aborted ```

Added subscriber: @rjg

Added subscriber: @rjg

Stack trace from ee8f69c96c

BKE_workspace_active_get(WorkSpaceInstanceHook * hook) Line 393	C
CTX_wm_window_set(bContext * C, wmWindow * win) Line 918	C
wm_handler_fileselect_do(bContext * C, ListBase * handlers, wmEventHandler_Op * handler, int val) Line 2390	C
wm_handler_fileselect_call(bContext * C, ListBase * handlers, wmEventHandler_Op * handler, const wmEvent * event) Line 2513	C
wm_handlers_do_intern(bContext * C, wmEvent * event, ListBase * handlers) Line 2900	C
wm_handlers_do(bContext * C, wmEvent * event, ListBase * handlers) Line 2952	C
wm_event_do_handlers(bContext * C) Line 3330	C
WM_main(bContext * C) Line 420	C
main(int argc, const unsigned char * * UNUSED_argv_c) Line 493	C
Stack trace from ee8f69c96cba ``` BKE_workspace_active_get(WorkSpaceInstanceHook * hook) Line 393 C CTX_wm_window_set(bContext * C, wmWindow * win) Line 918 C wm_handler_fileselect_do(bContext * C, ListBase * handlers, wmEventHandler_Op * handler, int val) Line 2390 C wm_handler_fileselect_call(bContext * C, ListBase * handlers, wmEventHandler_Op * handler, const wmEvent * event) Line 2513 C wm_handlers_do_intern(bContext * C, wmEvent * event, ListBase * handlers) Line 2900 C wm_handlers_do(bContext * C, wmEvent * event, ListBase * handlers) Line 2952 C wm_event_do_handlers(bContext * C) Line 3330 C WM_main(bContext * C) Line 420 C main(int argc, const unsigned char * * UNUSED_argv_c) Line 493 C ```
Member

Added subscriber: @JulianEisel

Added subscriber: @JulianEisel
Member

For the records, I'm investigating this, but it's a tricky one.
Basically the file browser handler is destroying the window currently set active by the event handling, which is left with dangling pointers then. One solution would be doing a delayed destruction of the window (like we sometimes delay closing of Blender, i.e. wm_exit_schedule_delayed()). However I'm trying to understand why this usually isn't an issue, but it's difficult to debug.

For the records, I'm investigating this, but it's a tricky one. Basically the file browser handler is destroying the window currently set active by the event handling, which is left with dangling pointers then. One solution would be doing a delayed destruction of the window (like we sometimes delay closing of Blender, i.e. `wm_exit_schedule_delayed()`). However I'm trying to understand why this usually isn't an issue, but it's difficult to debug.
Julian Eisel self-assigned this 2019-09-05 12:53:33 +02:00

This issue was referenced by fbf6898f58

This issue was referenced by fbf6898f583fe9982ca13366166a5505a94789ed
Member

Changed status from 'Open' to: 'Resolved'

Changed status from 'Open' to: 'Resolved'
Sign in to join this conversation.
No Label
Interest
Alembic
Interest
Animation & Rigging
Interest
Asset Browser
Interest
Asset Browser Project Overview
Interest
Audio
Interest
Automated Testing
Interest
Blender Asset Bundle
Interest
BlendFile
Interest
Collada
Interest
Compatibility
Interest
Compositing
Interest
Core
Interest
Cycles
Interest
Dependency Graph
Interest
Development Management
Interest
EEVEE
Interest
EEVEE & Viewport
Interest
Freestyle
Interest
Geometry Nodes
Interest
Grease Pencil
Interest
ID Management
Interest
Images & Movies
Interest
Import Export
Interest
Line Art
Interest
Masking
Interest
Metal
Interest
Modeling
Interest
Modifiers
Interest
Motion Tracking
Interest
Nodes & Physics
Interest
OpenGL
Interest
Overlay
Interest
Overrides
Interest
Performance
Interest
Physics
Interest
Pipeline, Assets & IO
Interest
Platforms, Builds & Tests
Interest
Python API
Interest
Render & Cycles
Interest
Render Pipeline
Interest
Sculpt, Paint & Texture
Interest
Text Editor
Interest
Translations
Interest
Triaging
Interest
Undo
Interest
USD
Interest
User Interface
Interest
UV Editing
Interest
VFX & Video
Interest
Video Sequencer
Interest
Virtual Reality
Interest
Vulkan
Interest
Wayland
Interest
Workbench
Interest: X11
Legacy
Blender 2.8 Project
Legacy
Milestone 1: Basic, Local Asset Browser
Legacy
OpenGL Error
Meta
Good First Issue
Meta
Papercut
Meta
Retrospective
Meta
Security
Module
Animation & Rigging
Module
Core
Module
Development Management
Module
EEVEE & Viewport
Module
Grease Pencil
Module
Modeling
Module
Nodes & Physics
Module
Pipeline, Assets & IO
Module
Platforms, Builds & Tests
Module
Python API
Module
Render & Cycles
Module
Sculpt, Paint & Texture
Module
Triaging
Module
User Interface
Module
VFX & Video
Platform
FreeBSD
Platform
Linux
Platform
macOS
Platform
Windows
Priority
High
Priority
Low
Priority
Normal
Priority
Unbreak Now!
Status
Archived
Status
Confirmed
Status
Duplicate
Status
Needs Info from Developers
Status
Needs Information from User
Status
Needs Triage
Status
Resolved
Type
Bug
Type
Design
Type
Known Issue
Type
Patch
Type
Report
Type
To Do
No Milestone
No project
No Assignees
5 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: blender/blender#69495
No description provided.