changeset 10948:747ef488c600

[gaim-migrate @ 12747] Fix for UNC paths. committer: Tailor Script <tailor@pidgin.im>
author Daniel Atallah <daniel.atallah@gmail.com>
date Fri, 27 May 2005 23:23:44 +0000
parents afc440485a9e
children 1adca5a37fb8
files src/util.c
diffstat 1 files changed, 8 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/src/util.c	Fri May 27 13:58:42 2005 +0000
+++ b/src/util.c	Fri May 27 23:23:44 2005 +0000
@@ -1901,6 +1901,14 @@
 
 		if(g_file_test(dir, G_FILE_TEST_IS_DIR)) {
 			continue;
+#ifdef _WIN32
+		/* allow us to create subdirs on UNC paths
+		 * (\\machinename\path\to\blah)
+		 * g_file_test() doesn't work on "\\machinename" */
+		} else if (cur == 2 && dir[0] == '\\' && dir[1] == '\\'
+				&& components[cur + 1] != NULL) {
+			continue;
+#endif
 		} else if(g_file_test(dir, G_FILE_TEST_EXISTS)) {
 			gaim_debug_warning("build_dir", "bad path: %s\n", path);
 			g_strfreev(components);