Enlightenment CVS committal Author : atmosphere Project : e17 Module : apps/entice
Dir : e17/apps/entice/src/bin Modified Files: prefs.c Log Message: fix problems if default.eet is in the pwd =================================================================== RCS file: /cvsroot/enlightenment/e17/apps/entice/src/bin/prefs.c,v retrieving revision 1.19 retrieving revision 1.20 diff -u -3 -r1.19 -r1.20 --- prefs.c 10 Oct 2004 00:58:24 -0000 1.19 +++ prefs.c 12 Jan 2005 02:18:54 -0000 1.20 @@ -95,13 +95,11 @@ entice_config_theme_get(void) { char buf[PATH_MAX]; + struct stat status; - if (econfig && econfig->theme) + if (econfig) { - struct stat status; - - /* theme doesn't exist by abs/relative path in db */ - if (stat(econfig->theme, &status) != 0) + if (econfig->theme) { snprintf(buf, PATH_MAX, "%s/.e/apps/entice/themes/%s", getenv("HOME"), econfig->theme); @@ -115,10 +113,13 @@ PACKAGE_DATA_DIR); } } - if (econfig->theme) - free(econfig->theme); - econfig->theme = strdup(buf); + free(econfig->theme); + } + else + { + snprintf(buf, PATH_MAX, "%s/themes/default.eet", PACKAGE_DATA_DIR); } + econfig->theme = strdup(buf); return (econfig->theme); } return (NULL); ------------------------------------------------------- The SF.Net email is sponsored by: Beat the post-holiday blues Get a FREE limited edition SourceForge.net t-shirt from ThinkGeek. It's fun and FREE -- well, almost....http://www.thinkgeek.com/sfshirt _______________________________________________ enlightenment-cvs mailing list enlightenment-cvs@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs