core/service: fix memleak of USBFunctionStrings and USBFunctionDescriptors

oss-fuzz #6892.
This commit is contained in:
Zbigniew Jędrzejewski-Szmek
2018-03-17 09:01:53 +01:00
parent 4b8d0cdf04
commit 064c593899
3 changed files with 7 additions and 0 deletions
+3
View File
@@ -396,6 +396,9 @@ static void service_done(Unit *u) {
s->bus_name_owner = mfree(s->bus_name_owner);
s->usb_function_descriptors = mfree(s->usb_function_descriptors);
s->usb_function_strings = mfree(s->usb_function_strings);
service_close_socket_fd(s);
s->peer = socket_peer_unref(s->peer);