aboutsummaryrefslogtreecommitdiffstats
path: root/libgamepad_destroy_attachment_monitor.c
blob: bdddb83e3164c98686a831f41e121ecc671bf887 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
/* See LICENSE file for copyright and license details. */
#include "common.h"


void
libgamepad_destroy_attachment_monitor(LIBGAMEPAD_ATTACHMENT_MONITOR *monitor)
{
	if (monitor) {
		if (monitor->monitor)
			udev_monitor_unref(monitor->monitor);
		if (monitor->udev)
			udev_unref(monitor->udev);
		free(monitor);
	}
}