diff -Naur a/contrib/mc-wrapper.csh.in b/contrib/mc-wrapper.csh.in
--- a/contrib/mc-wrapper.csh.in	2025-01-11 23:51:01.000000000 +0600
+++ b/contrib/mc-wrapper.csh.in	2025-01-24 16:52:12.797670399 +0600
@@ -3,7 +3,7 @@
 else if ($?TMPDIR) then
 	setenv MC_PWD_FILE "`mktemp '$TMPDIR/mc.pwd.XXXXXX'`"
 else
-	setenv MC_PWD_FILE "`mktemp '/tmp/mc.pwd.XXXXXX'`"
+	setenv MC_PWD_FILE "`mktemp '/var/tmp/mc.pwd.XXXXXX'`"
 endif
 
 @bindir@/mc -P "$MC_PWD_FILE" $*
diff -Naur a/contrib/mc-wrapper.sh.in b/contrib/mc-wrapper.sh.in
--- a/contrib/mc-wrapper.sh.in	2025-01-11 23:51:01.000000000 +0600
+++ b/contrib/mc-wrapper.sh.in	2025-01-24 16:52:01.293741145 +0600
@@ -3,7 +3,7 @@
 elif test -n "$TMPDIR"; then
 	MC_PWD_FILE="`mktemp "${TMPDIR}/mc.pwd.XXXXXX"`"
 else
-	MC_PWD_FILE="`mktemp "/tmp/mc.pwd.XXXXXX"`"
+	MC_PWD_FILE="`mktemp "/var/tmp/mc.pwd.XXXXXX"`"
 fi
 
 @bindir@/mc -P "$MC_PWD_FILE" "$@"
diff -Naur a/lib/unixcompat.h b/lib/unixcompat.h
--- a/lib/unixcompat.h	2025-01-11 23:51:01.000000000 +0600
+++ b/lib/unixcompat.h	2025-01-24 16:56:14.605185482 +0600
@@ -108,7 +108,7 @@
 #define PATH_SEP_STR "/"
 #define IS_PATH_SEP(c) ((c) == PATH_SEP)
 #define PATH_ENV_SEP ':'
-#define TMPDIR_DEFAULT "/tmp"
+#define TMPDIR_DEFAULT "/var/tmp"
 #define SCRIPT_SUFFIX ""
 #define get_default_editor() "vi"
 #define OS_SORT_CASE_SENSITIVE_DEFAULT TRUE
