Commit 57cf9b4b authored by Philippe De Swert's avatar Philippe De Swert

restart udev trigger when socket gets destroyed

Signed-off-by: default avatarPhilippe De Swert <phdeswer@lumi.maa>
parent d0f46162
usb-moded (0.46) unstable; urgency=low
* Restart usb trigger if the socket gets destroyed.
-- Philippe De Swert <philippe.de-swert@nokia.com> Mon, 15 Aug 2011 15:28:16 +0300
usb-moded (0.45) unstable; urgency=low
* Only signal MODE_UNDEFINED when we have actually done all the modesetting handling
......
......@@ -53,6 +53,14 @@ static gboolean monitor_udev(GIOChannel *iochannel G_GNUC_UNUSED, GIOCondition c
gpointer data G_GNUC_UNUSED);
static void udev_parse(struct udev_device *dev);
static void notify_issue (gpointer data)
{
log_debug("trigger watch destroyed\n!");
/* restart trigger */
trigger_init();
}
gboolean trigger_init(void)
{
const gchar *udev_path = NULL;
......@@ -109,7 +117,7 @@ gboolean trigger_init(void)
udev_parse(dev);
iochannel = g_io_channel_unix_new(udev_monitor_get_fd(mon));
watch_id = g_io_add_watch(iochannel, G_IO_IN, monitor_udev, NULL);
watch_id = g_io_add_watch_full(iochannel, 0, G_IO_IN, monitor_udev, NULL, notify_issue);
/* everything went well */
log_debug("Trigger enabled!\n");
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment