From 26c77cfc148c057140807820276844fb6376cb42 Mon Sep 17 00:00:00 2001
From: Yorhel <git@yorhel.nl>
Date: Sat, 6 Jun 2009 23:22:49 +0200
Subject: [PATCH] Return to previously opened directory on failed recalculation

...instead of displaying an empty and unusable browser.
---
 ChangeLog  | 1 +
 src/calc.c | 2 +-
 2 files changed, 2 insertions(+), 1 deletion(-)

diff --git a/ChangeLog b/ChangeLog
index bc7a44e..71a2be3 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -4,6 +4,7 @@ git - ?
 	- Removed reliance of dirfd()
 	- Fixed non-void return in void delete_process()
 	- Fixed several tiny memory leaks
+	- Return to previously opened directory on failed recalculation
 
 1.5 - 2009-05-02
 	- Fixed incorrect apparent size on directory refresh
diff --git a/src/calc.c b/src/calc.c
index cceb9a9..fff2cd6 100644
--- a/src/calc.c
+++ b/src/calc.c
@@ -428,7 +428,7 @@ calc_fail:
   if(orig == NULL)
     return 1;
   else {
-    browse_init(NULL);
+    browse_init(orig);
     return 0;
   }
 }
-- 
GitLab