Completely reworked the path convertion functions
[mmh] / sbr / m_mktemp.c
index c0c1a9c..4a1eed1 100644 (file)
@@ -119,7 +119,7 @@ m_mktemp2(
                return m_mktemp(buffer, fd_ret, fp_ret);
        }
 
-       if ((cp = r1bindex((char *)dir_in, '/')) == dir_in) {
+       if ((cp = mhbasename((char *)dir_in)) == dir_in) {
                /* No directory component */
                return m_mktemp(pfx_in, fd_ret, fp_ret);
        }
@@ -144,5 +144,5 @@ get_temp_dir()
                tmpdir = getenv("TMP");
                if (tmpdir != NULL && *tmpdir != '\0') return tmpdir;
        }
-       return m_maildir("");
+       return toabsdir("+");
 }