chris: I don't see where I'm misusing the return value of g_get_user_special_dir(). transmission calls it three times, all in tr_prefs_init_defaults(), and puts the return value in a const char* each time.
My guess is that the first time you run Transmission, it gets the g_get_user_special_dir(G_USER_DOWNLOAD_DIRECTORY) and stores it in ~/.config/transmission/settings.json, and reads it from there in subsequent sessions. So if you change XDG_DOWNLOAD_DIR *after* that first session, then there's some shear between settings.json and XDG_DOWNLOAD_DIR.
If that's what's going on, I'd agree that it's a little odd, but I wouldn't call it a bug -- the alternative would be to get rid of the configuration option and always defer to XDG_DOWNLOAD_DIR, but that would preclude users from having custom watch & download directories for torrents... which is something a large percentage of Transmission users do...
chris: I don't see where I'm misusing the return value of g_get_user_ special_ dir(). transmission calls it three times, all in tr_prefs_ init_defaults( ), and puts the return value in a const char* each time.
My guess is that the first time you run Transmission, it gets the g_get_user_ special_ dir(G_USER_ DOWNLOAD_ DIRECTORY) and stores it in ~/.config/ transmission/ settings. json, and reads it from there in subsequent sessions. So if you change XDG_DOWNLOAD_DIR *after* that first session, then there's some shear between settings.json and XDG_DOWNLOAD_DIR.
If that's what's going on, I'd agree that it's a little odd, but I wouldn't call it a bug -- the alternative would be to get rid of the configuration option and always defer to XDG_DOWNLOAD_DIR, but that would preclude users from having custom watch & download directories for torrents... which is something a large percentage of Transmission users do...