Moved from bug 717, comment #16 and #17. The workaround does not work. This is because the XDG module checks the environment when the modules are *imported*. This happens before we change to "C".