SF.net SVN: geany:[3777] trunk

eht16 at users.sourceforge.net eht16 at xxxxx
Sun May 10 17:44:43 UTC 2009


Revision: 3777
          http://geany.svn.sourceforge.net/geany/?rev=3777&view=rev
Author:   eht16
Date:     2009-05-10 17:44:43 +0000 (Sun, 10 May 2009)

Log Message:
-----------
Create parent directories if necessary when checking for the configuration directory on startup (closes #2784577).

Modified Paths:
--------------
    trunk/ChangeLog
    trunk/src/main.c

Modified: trunk/ChangeLog
===================================================================
--- trunk/ChangeLog	2009-05-10 17:44:28 UTC (rev 3776)
+++ trunk/ChangeLog	2009-05-10 17:44:43 UTC (rev 3777)
@@ -5,6 +5,9 @@
    on the press event like for other buttons.
  * src/editor.c:
    Refactor some multiple used code into get_multiline_comment_style().
+ * src/main.c:
+   Create parent directories if necessary when checking for the
+   configuration directory on startup (closes #2784577).
 
 
 2009-05-08  Enrico Tröger  <enrico(dot)troeger(at)uvena(dot)de>

Modified: trunk/src/main.c
===================================================================
--- trunk/src/main.c	2009-05-10 17:44:28 UTC (rev 3776)
+++ trunk/src/main.c	2009-05-10 17:44:43 UTC (rev 3777)
@@ -634,6 +634,9 @@
 					_("Geany needs to move your old configuration directory before starting.")))
 					exit(0);
 
+				if (! g_file_test(app->configdir, G_FILE_TEST_IS_DIR))
+					utils_mkdir(app->configdir, TRUE);
+
 				if (g_rename(old_dir, app->configdir) == 0)
 				{
 					dialogs_show_msgbox(GTK_MESSAGE_INFO,
@@ -656,7 +659,7 @@
 		}
 #endif
 		geany_debug("creating config directory %s", app->configdir);
-		saved_errno = utils_mkdir(app->configdir, FALSE);
+		saved_errno = utils_mkdir(app->configdir, TRUE);
 	}
 
 	if (saved_errno == 0 && ! g_file_test(conf_file, G_FILE_TEST_EXISTS))


This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.



More information about the Commits mailing list