add logic to default to XDG disabled

- defaults to XDG disabled unless the directory is present
This commit is contained in:
altffour 2021-01-06 19:46:52 +03:00
commit 9123c6f178
No known key found for this signature in database
GPG key ID: B4ADFA86EDF5CCE9

View file

@ -200,6 +200,7 @@ void core_preinit(const char *path)
char *str; char *str;
int len; int len;
xdg_support = 0;
if (irssi_dir == NULL) { if (irssi_dir == NULL) {
/* check if %XDG_CONFIG_HOME/irssi exists and default to it */ /* check if %XDG_CONFIG_HOME/irssi exists and default to it */
char *dirp = g_build_filename(g_get_user_config_dir(), "irssi", NULL); char *dirp = g_build_filename(g_get_user_config_dir(), "irssi", NULL);