[Mono-bugs] [Bug 52056][Nor] Changed - System.IO.Path.GetTempPath() does not end with DirectorySeparatorChar
bugzilla-daemon@bugzilla.ximian.com
bugzilla-daemon@bugzilla.ximian.com
Thu, 11 Dec 2003 13:57:52 -0500 (EST)
Please do not reply to this email- if you want to comment on the bug, go to the
URL shown below and enter your comments there.
Changed by ginga@kit.hi-ho.ne.jp.
http://bugzilla.ximian.com/show_bug.cgi?id=52056
--- shadow/52056 2003-12-11 13:14:31.000000000 -0500
+++ shadow/52056.tmp.17713 2003-12-11 13:57:52.000000000 -0500
@@ -66,6 +66,24 @@
[out] Pointer to a string buffer that receives the null-terminated
string specifying the temporary file path. The returned string ends
with a backslash, for example, C:\TEMP\.
Are we calling this api? Also, is it possible they have a lamespec
there!? (I wouldn't put it past them ;-)
+
+------- Additional Comments From ginga@kit.hi-ho.ne.jp 2003-12-11 13:57 -------
+Mono uses g_get_tmp_dir() in glib (mono/mono/metadata/icall.c).
+
+g_get_tmp_dir(): http://cvs.gnome.org/bonsai/cvsblame.cgi?file=glib%
+2Fglib/gutils.c&rev=&root=/cvs/gnome
+
+you can check g_get_any_init (void) for detail:
+
+if (k > 1 && G_IS_DIR_SEPARATOR (g_tmp_dir[k - 1]))
+ g_tmp_dir[k - 1] = '\0';
+
+I have no idea if this line is actually used (possibly no effect by
+ifdef), but if this line is alive, then glib eliminates the last
+directory separator from %tmp%.
+
+So I think this should be corrected to contain last separator
+character.