Duplicating Nodes Crashes Blender #73493

Closed
opened 2020-01-29 16:20:35 +01:00 by Krusty Krustowski · 9 comments

System Information
Operating system: Windows-10-10.0.18362-SP0 64 Bits
Graphics card: GeForce GTX 1050 Ti/PCIe/SSE2 NVIDIA Corporation 4.5.0 NVIDIA 442.01

Blender Version
Broken: version: 2.83 (sub 1), branch: master, commit date: 2020-01-29 00:11, hash: 7642ee627a

Short description of error
Duplicating nodes through context menu(Right Click) crashes Blender.

Exact steps for others to reproduce the error
Open Blender, go to any Node-based editor and try to duplicate a node through context menu

**System Information** Operating system: Windows-10-10.0.18362-SP0 64 Bits Graphics card: GeForce GTX 1050 Ti/PCIe/SSE2 NVIDIA Corporation 4.5.0 NVIDIA 442.01 **Blender Version** Broken: version: 2.83 (sub 1), branch: master, commit date: 2020-01-29 00:11, hash: `7642ee627a` **Short description of error** Duplicating nodes through context menu(Right Click) crashes Blender. **Exact steps for others to reproduce the error** Open Blender, go to any Node-based editor and try to duplicate a node through context menu

Added subscriber: @Blendork

Added subscriber: @Blendork

Added subscriber: @rjg

Added subscriber: @rjg

I can't reproduce this with the most recent master but I can confirm that this issue was occurring in a554ff9693. I'm checking but it seems like this might have been fixed by 7c9b5523ff.

I can't reproduce this with the most recent master but I can confirm that this issue was occurring in a554ff9693. I'm checking but it seems like this might have been fixed by 7c9b5523ff.

Added subscriber: @SteffenD

Added subscriber: @SteffenD

No crashes for me in latest 2.83 (e3f89237fe). Tried duplicating Shader nodes and Compositor nodes.

No crashes for me in latest 2.83 (e3f89237fecc). Tried duplicating Shader nodes and Compositor nodes.

Added subscriber: @JulianEisel

Added subscriber: @JulianEisel

The crash doesn't occur after 7c9b5523ff.

@JulianEisel the cause was an invalid pointer passed as v2d into UI_view2d_view_to_region() (view2d.c ). Does your patch fix this completely or could there be another bug here?

Stack trace for 3ee219b845

UI_view2d_view_to_region(View2D * v2d, float x, float y, int * r_region_x, int * r_region_y) Line 1808	C
projectIntViewEx(TransInfo * t, const float * vec, int * adr, const <unnamed-enum-V3D_PROJ_TEST_NOP> flag) Line 487	C
projectIntView(TransInfo * t, const float * vec, int * adr) Line 491	C
projectFloatViewEx(TransInfo * t, const float * vec, float * adr, const <unnamed-enum-V3D_PROJ_TEST_NOP> flag) Line 515	C
projectFloatView(TransInfo * t, const float * vec, float * adr) Line 524	C
calculateCenter2D(TransInfo * t) Line 2054	C
setTransformViewMatrices(TransInfo * t) Line 255	C
initTransInfo(bContext * C, TransInfo * t, wmOperator * op, const wmEvent * event) Line 1848	C
initTransform(bContext * C, TransInfo * t, wmOperator * op, const wmEvent * event, int mode) Line 2096	C
transformops_data(bContext * C, wmOperator * op, const wmEvent * event) Line 382	C
transform_invoke(bContext * C, wmOperator * op, const wmEvent * event) Line 498	C
wm_macro_invoke_internal(bContext * C, wmOperator * op, const wmEvent * event, wmOperator * opm) Line 364	C
wm_macro_invoke(bContext * C, wmOperator * op, const wmEvent * event) Line 390	C
wm_operator_invoke(bContext * C, wmOperatorType * ot, wmEvent * event, PointerRNA * properties, ReportList * reports, const bool poll_only, bool use_last_properties) Line 1257	C
wm_operator_call_internal(bContext * C, wmOperatorType * ot, PointerRNA * properties, ReportList * reports, const short context, const bool poll_only, wmEvent * event) Line 1504	C
WM_operator_name_call_ptr(bContext * C, wmOperatorType * ot, short context, PointerRNA * properties) Line 1519	C
ui_apply_but_funcs_after(bContext * C) Line 880	C
ui_popup_handler(bContext * C, const wmEvent * event, void * userdata) Line 10782	C
wm_handler_ui_call(bContext * C, wmEventHandler_UI * handler, const wmEvent * event, int always_pass) Line 617	C
wm_handlers_do_intern(bContext * C, wmEvent * event, ListBase * handlers) Line 2543	C
wm_handlers_do(bContext * C, wmEvent * event, ListBase * handlers) Line 2789	C
wm_event_do_handlers(bContext * C) Line 3168	C
WM_main(bContext * C) Line 421	C
main(int argc, const unsigned char * * UNUSED_argv_c) Line 520	C
The crash doesn't occur after 7c9b5523ff. @JulianEisel the cause was an invalid pointer passed as `v2d` into `UI_view2d_view_to_region()` ([view2d.c ](https://developer.blender.org/diffusion/B/browse/master/source/blender/editors/interface/view2d.c)). Does your patch fix this completely or could there be another bug here? Stack trace for 3ee219b845 ``` UI_view2d_view_to_region(View2D * v2d, float x, float y, int * r_region_x, int * r_region_y) Line 1808 C projectIntViewEx(TransInfo * t, const float * vec, int * adr, const <unnamed-enum-V3D_PROJ_TEST_NOP> flag) Line 487 C projectIntView(TransInfo * t, const float * vec, int * adr) Line 491 C projectFloatViewEx(TransInfo * t, const float * vec, float * adr, const <unnamed-enum-V3D_PROJ_TEST_NOP> flag) Line 515 C projectFloatView(TransInfo * t, const float * vec, float * adr) Line 524 C calculateCenter2D(TransInfo * t) Line 2054 C setTransformViewMatrices(TransInfo * t) Line 255 C initTransInfo(bContext * C, TransInfo * t, wmOperator * op, const wmEvent * event) Line 1848 C initTransform(bContext * C, TransInfo * t, wmOperator * op, const wmEvent * event, int mode) Line 2096 C transformops_data(bContext * C, wmOperator * op, const wmEvent * event) Line 382 C transform_invoke(bContext * C, wmOperator * op, const wmEvent * event) Line 498 C wm_macro_invoke_internal(bContext * C, wmOperator * op, const wmEvent * event, wmOperator * opm) Line 364 C wm_macro_invoke(bContext * C, wmOperator * op, const wmEvent * event) Line 390 C wm_operator_invoke(bContext * C, wmOperatorType * ot, wmEvent * event, PointerRNA * properties, ReportList * reports, const bool poll_only, bool use_last_properties) Line 1257 C wm_operator_call_internal(bContext * C, wmOperatorType * ot, PointerRNA * properties, ReportList * reports, const short context, const bool poll_only, wmEvent * event) Line 1504 C WM_operator_name_call_ptr(bContext * C, wmOperatorType * ot, short context, PointerRNA * properties) Line 1519 C ui_apply_but_funcs_after(bContext * C) Line 880 C ui_popup_handler(bContext * C, const wmEvent * event, void * userdata) Line 10782 C wm_handler_ui_call(bContext * C, wmEventHandler_UI * handler, const wmEvent * event, int always_pass) Line 617 C wm_handlers_do_intern(bContext * C, wmEvent * event, ListBase * handlers) Line 2543 C wm_handlers_do(bContext * C, wmEvent * event, ListBase * handlers) Line 2789 C wm_event_do_handlers(bContext * C) Line 3168 C WM_main(bContext * C) Line 421 C main(int argc, const unsigned char * * UNUSED_argv_c) Line 520 C ```
Member

Changed status from 'Needs Triage' to: 'Resolved'

Changed status from 'Needs Triage' to: 'Resolved'
Julian Eisel self-assigned this 2020-01-29 17:32:15 +01:00
Member

It was probably caused by a NULL pointer de-reference when accessing View2D through the context region - which was likely NULL after my changes.
So no, I don't think there's another bug involved.

It was probably caused by a `NULL` pointer de-reference when accessing View2D through the context region - which was likely `NULL` after my changes. So no, I don't think there's another bug involved.
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
4 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#73493
No description provided.