Mon, 09 May 2022 20:31:30 +0200
fix crash in davql exec, if the server response can't be parsed
libidav/davqlexec.c | file | annotate | diff | comparison | revisions |
--- a/libidav/davqlexec.c Mon Aug 09 19:01:02 2021 +0200 +++ b/libidav/davqlexec.c Mon May 09 20:31:30 2022 +0200 @@ -627,7 +627,11 @@ // propfind request successful, now parse the response char *url = "http://url/"; PropfindParser *parser = create_propfind_parser(rpbuf, url); - // TODO: test if parser is null + if(!parser) { + result.status = -1; + break; + } + ResponseTag response; int r; while((r = get_propfind_response(parser, &response)) != 0) {