Fixed Xresources settings storage mechanism

The Xresources settings now get stored and loaded from Putty sessions
correctly. Fixed storage/loading of file name, type, as well as
applications string. Modified the logic for storing environment
variables to avoid interference with Xresources map.