Don't crash if $HOME is empty
Don't crash if $HOME is empty

If both $XDG_CONFIG_HOME and $HOME are unset, we'd try to copy a NULL
string, causing a crash. This is the environment systemd provides to
its daemons, and that was causing upowerd to crash.

http://libiphone.lighthouseapp.com/projects/27916-libiphone/tickets/273-patch-fix-segfault-when-running-with-home-unset#ticket-273-2
http://libiphone.lighthouseapp.com/projects/27916/tickets/265-userpref_get_config_dir-segfaults-when-home-is-undefined
https://bugzilla.redhat.com/show_bug.cgi?id=834359

libimobiledevice-win32/libimobiledevice,Tatsh/libimobiledevice,kalev/libimobiledevice,libimobiledevice/libimobiledevice,Tatsh/libimobiledevice,libimobiledevice-win32/libimobiledevice,kalev/libimobiledevice,kalev/libimobiledevice,upbit/libimobiledevice,Tatsh/libimobiledevice,patweb/libimobiledevice,patweb/libimobiledevice,libimobiledevice/libimobiledevice,Tatsh/libimobiledevice,upbit/libimobiledevice,libimobiledevice-win32/libimobiledevice,patweb/libimobiledevice,libimobiledevice-win32/libimobiledevice,upbit/libimobiledevice