From a28736b03b50ff37ce2cd0fb2fa1ef2e37508108 Mon Sep 17 00:00:00 2001 From: root Date: Thu, 9 Aug 2012 00:02:24 +0000 Subject: Thu Aug 9 00:02:24 UTC 2012 --- extra/libimobiledevice/HOME-segfault.patch | 14 ++++++++++++++ 1 file changed, 14 insertions(+) create mode 100644 extra/libimobiledevice/HOME-segfault.patch (limited to 'extra/libimobiledevice/HOME-segfault.patch') diff --git a/extra/libimobiledevice/HOME-segfault.patch b/extra/libimobiledevice/HOME-segfault.patch new file mode 100644 index 000000000..e48e6cb42 --- /dev/null +++ b/extra/libimobiledevice/HOME-segfault.patch @@ -0,0 +1,14 @@ +The patch fixes segfault when both $XDG_CONFIG_HOME and $HOME are unset +Signed-off-by: Maxim Mikityanskiy +--- src/userpref.c.orig 2012-06-04 17:04:57.387303630 +0300 ++++ src/userpref.c 2012-06-04 17:06:05.741301627 +0300 +@@ -125,6 +125,9 @@ + const char *cdir = getenv("XDG_CONFIG_HOME"); + if (!cdir) { + cdir = getenv("HOME"); ++ if (!cdir) { ++ cdir="/root"; ++ } + strcpy(__config_dir, cdir); + strcat(__config_dir, DIR_SEP_S); + strcat(__config_dir, ".config"); -- cgit v1.2.3-54-g00ecf