Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
View | Details | Raw Unified | Return to bug 231678 | Differences between
and this patch

Collapse All | Expand All

(-)gpilotd/gpilotd.c-old (-4 / +12 lines)
Lines 1079-1085 Link Here
1079
hal_device_added (LibHalContext *ctx, const char *udi)
1079
hal_device_added (LibHalContext *ctx, const char *udi)
1080
{
1080
{
1081
	gboolean visor_net = FALSE;
1081
	gboolean visor_net = FALSE;
1082
	char *bus, *match_str;
1082
	char *bus, *platform, *match_str;
1083
	int vendor_id, product_id, i;
1083
	int vendor_id, product_id, i;
1084
	GPilotDevice *device;
1084
	GPilotDevice *device;
1085
	DBusError error;
1085
	DBusError error;
Lines 1090-1104 Link Here
1090
1090
1091
	load_devices_xml ();
1091
	load_devices_xml ();
1092
1092
1093
	/* HAL match rule: we look for info.bus == 'usb_device'
1093
	/* HAL match rule: we look for pda.platform == 'palm'
1094
	 * (or the legacy info.bus == 'usb_device')
1094
	 * and then try to match the usb_device.product_id and usb_device.vendor_id
1095
	 * and then try to match the usb_device.product_id and usb_device.vendor_id
1095
	 * against the list in devices.xml.
1096
	 * against the list in devices.xml.
1096
	 */
1097
	 */
1097
	if (!(bus = libhal_device_get_property_string (hal_ctx, udi, "info.bus", NULL)))
1098
	if (platform = libhal_device_get_property_string (hal_ctx, udi, "pda.platform", NULL)) {
1099
	    if (strcmp (platform, "palm") != 0) {
1100
		libhal_free_string (platform);
1098
		return;
1101
		return;
1099
	if (strcmp (bus, "usb_device") != 0) {
1102
	    }
1103
	} else if (bus = libhal_device_get_property_string (hal_ctx, udi, "info.bus", NULL)) {
1104
	    if (strcmp (bus, "usb_device") != 0) {
1100
		libhal_free_string (bus);
1105
		libhal_free_string (bus);
1101
		return;
1106
		return;
1107
	    }
1108
	} else {
1109
	    return;
1102
	}
1110
	}
1103
1111
1104
	dbus_error_init (&error);
1112
	dbus_error_init (&error);

Return to bug 231678