aboutsummaryrefslogtreecommitdiffstats
path: root/main.c
diff options
context:
space:
mode:
Diffstat (limited to 'main.c')
-rw-r--r--main.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/main.c b/main.c
index 85b0003..b99928c 100644
--- a/main.c
+++ b/main.c
@@ -5972,6 +5972,11 @@ w3m_exit(int i)
#ifdef __MINGW32_VERSION
WSACleanup();
#endif
+ if (no_rc_dir && tmp_dir != rc_dir)
+ if (rmdir(tmp_dir) != 0) {
+ fprintf(stderr, "Can't remove temporary directory (%s)!\n", tmp_dir);
+ exit(1);
+ }
exit(i);
}