Memory leak in dropper tool (cursor logic)
Reported by @Tremeschin in inbox#4844 (comment 644631559)
Steps to reproduce:
- open Inkscape
- Switch to Dropper tool
- Click and drag (creates circle)
- Drag for a bit
What happened?
- Quick memory growth (20 to 30 MB/s of RAM and uses about 16% CPU)
ASAN logs: inkscape_asan_dropper_cb5af3f7be.txt
As you would expect from those logs, this stops the memory leak (not a fix)
diff --git a/src/ui/tools/dropper-tool.cpp b/src/ui/tools/dropper-tool.cpp
index e04c637f10..e27d7e9db5 100644
--- a/src/ui/tools/dropper-tool.cpp
+++ b/src/ui/tools/dropper-tool.cpp
@@ -389,7 +389,7 @@ bool DropperTool::root_handler(GdkEvent* event) {
// We do this ourselves to get color correct.
auto display = desktop->getCanvas()->get_display();
auto window = desktop->getCanvas()->get_window();
- load_svg_cursor(display, window, cursor_filename, get_color(invert));
+ // load_svg_cursor(display, window, cursor_filename, get_color(invert));
if (!ret) {
ret = ToolBase::root_handler(event);
What should have happened?
- no memory leak
Inkscape Version and Operating System:
Edited by Nathan Lee