From 1d844aae7820d10abf9a19b7acfb88341ac6e961 Mon Sep 17 00:00:00 2001 From: BALATON Zoltan Date: Tue, 7 Feb 2017 17:17:03 +0100 Subject: Fix parameter check of instproxy_check_capabilities_match() The capabilities parameter is a string array not a plist. Also check other parameters when we are at it. --- src/installation_proxy.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/installation_proxy.c b/src/installation_proxy.c index 9f367aa..f82eecc 100644 --- a/src/installation_proxy.c +++ b/src/installation_proxy.c @@ -772,7 +772,7 @@ LIBIMOBILEDEVICE_API instproxy_error_t instproxy_remove_archive(instproxy_client LIBIMOBILEDEVICE_API instproxy_error_t instproxy_check_capabilities_match(instproxy_client_t client, const char** capabilities, plist_t client_options, plist_t *result) { - if (!capabilities || (plist_get_node_type(capabilities) != PLIST_ARRAY && plist_get_node_type(capabilities) != PLIST_DICT)) + if (!client || !capabilities || !result) return INSTPROXY_E_INVALID_ARG; plist_t lookup_result = NULL; -- cgit v1.1-32-gdbae