summaryrefslogtreecommitdiffstats
path: root/src/main.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/main.c')
-rw-r--r--src/main.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/main.c b/src/main.c
index bb2eb2c..7ae3532 100644
--- a/src/main.c
+++ b/src/main.c
@@ -47,9 +47,10 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
47#include "device.h" 47#include "device.h"
48#include "client.h" 48#include "client.h"
49 49
50extern const char* userpref_get_config_dir();
51
50static const char *socket_path = "/var/run/usbmuxd"; 52static const char *socket_path = "/var/run/usbmuxd";
51static const char *lockfile = "/var/run/usbmuxd.pid"; 53static const char *lockfile = "/var/run/usbmuxd.pid";
52static const char *userprefdir = "/var/lib/lockdown";
53 54
54int should_exit; 55int should_exit;
55int should_discover; 56int should_discover;
@@ -529,6 +530,8 @@ int main(int argc, char *argv[])
529 if(listenfd < 0) 530 if(listenfd < 0)
530 goto terminate; 531 goto terminate;
531 532
533 const char* userprefdir = userpref_get_config_dir();
534
532 struct stat fst; 535 struct stat fst;
533 int userprefdir_created = 0; 536 int userprefdir_created = 0;
534 if (stat(userprefdir, &fst) < 0) { 537 if (stat(userprefdir, &fst) < 0) {