mirror of
https://github.com/morgan9e/UxPlay
synced 2026-04-14 00:04:13 +09:00
fix some plist not-freed memory leaks
This commit is contained in:
@@ -334,6 +334,7 @@ conn_request(void *ptr, http_request_t *request, http_response_t **response) {
|
||||
char * plist_xml;
|
||||
uint32_t plist_len;
|
||||
plist_to_xml(res_root_node, &plist_xml, &plist_len);
|
||||
plist_free(res_root_node);
|
||||
logger_log(conn->raop->logger, LOGGER_DEBUG, "%s", plist_xml);
|
||||
free(plist_xml);
|
||||
} else if (data_is_text) {
|
||||
|
||||
@@ -548,6 +548,8 @@ raop_handler_setup(raop_conn_t *conn,
|
||||
}
|
||||
|
||||
plist_to_bin(res_root_node, response_data, (uint32_t*) response_datalen);
|
||||
plist_free(res_root_node);
|
||||
plist_free(req_root_node);
|
||||
http_response_add_header(response, "Content-Type", "application/x-apple-binary-plist");
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user