[gnome-commander] Revert "Free unused memory after creating a parent GnomeCmdDir"



commit a761a693a53fa44b39827d830bc1706773367c50
Author: Uwe Scholz <u scholz83 gmx de>
Date:   Sat Nov 13 22:49:10 2021 +0100

    Revert "Free unused memory after creating a parent GnomeCmdDir"
    
    This reverts commit 02abdb4e2b8c92a6ab868b422bfaf7a7e1fad018.
    
    Looks like this is commit is responsible for random crashes.

 src/gnome-cmd-dir.cc | 6 +-----
 1 file changed, 1 insertion(+), 5 deletions(-)
---
diff --git a/src/gnome-cmd-dir.cc b/src/gnome-cmd-dir.cc
index 3844381e..4d9b89c1 100644
--- a/src/gnome-cmd-dir.cc
+++ b/src/gnome-cmd-dir.cc
@@ -380,11 +380,7 @@ GnomeCmdDir *gnome_cmd_dir_get_parent (GnomeCmdDir *dir)
 
     GnomeCmdPath *path = dir->priv->path->get_parent();
 
-    auto gnomeCmdDir = path ? gnome_cmd_dir_new (dir->priv->con, path) : nullptr;
-
-    delete path;
-
-    return gnomeCmdDir;
+    return path ? gnome_cmd_dir_new (dir->priv->con, path) : nullptr;
 }
 
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]