Changeset 5368 in vbox
- Timestamp:
- Oct 18, 2007 9:57:06 AM (18 years ago)
- svn:sync-xref-src-repo-rev:
- 25436
- Location:
- trunk/src/VBox/Main
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Main/HostImpl.cpp
r5217 r5368 1605 1605 { 1606 1606 int numDevices; 1607 char **halDevices = gLibHalFindDeviceByCapability(halContext, 1608 "storage.cdrom", &numDevices, &dbusError); 1607 char **halDevices = gLibHalFindDeviceStringMatch(halContext, 1608 "storage.drive_type", "cdrom", 1609 &numDevices, &dbusError); 1609 1610 if (halDevices != 0) 1610 1611 { … … 1624 1625 if (devNode != 0) 1625 1626 { 1626 if (validateDevice(devNode, true))1627 {1627 // if (validateDevice(devNode, true)) 1628 // { 1628 1629 Utf8Str description; 1629 1630 char *vendor, *product; … … 1674 1675 gLibHalFreeString(product); 1675 1676 } 1676 }1677 else1678 {1679 LogRel(("Host::COMGETTER(DVDDrives): failed to validate the block device %s as a DVD drive\n"));1680 }1677 // } 1678 // else 1679 // { 1680 // LogRel(("Host::COMGETTER(DVDDrives): failed to validate the block device %s as a DVD drive\n")); 1681 // } 1681 1682 #ifndef RT_OS_SOLARIS 1682 1683 gLibHalFreeString(devNode); … … 1757 1758 { 1758 1759 int numDevices; 1759 char **halDevices = gLibHalFindDeviceByCapability(halContext, 1760 "storage", &numDevices, &dbusError); 1760 char **halDevices = gLibHalFindDeviceStringMatch(halContext, 1761 "storage.drive_type", "floppy", 1762 &numDevices, &dbusError); 1761 1763 if (halDevices != 0) 1762 1764 { … … 1787 1789 if (devNode != 0) 1788 1790 { 1789 if (validateDevice(devNode, false))1790 {1791 // if (validateDevice(devNode, false)) 1792 // { 1791 1793 Utf8Str description; 1792 1794 char *vendor, *product; … … 1837 1839 gLibHalFreeString(product); 1838 1840 } 1839 }1840 else1841 {1842 LogRel(("Host::COMGETTER(FloppyDrives): failed to validate the block device %s as a floppy drive\n"));1843 }1841 // } 1842 // else 1843 // { 1844 // LogRel(("Host::COMGETTER(FloppyDrives): failed to validate the block device %s as a floppy drive\n")); 1845 // } 1844 1846 gLibHalFreeString(devNode); 1845 1847 } -
trunk/src/VBox/Main/include/vbox-libhal.h
r4071 r5368 53 53 extern dbus_bool_t (*gLibHalCtxSetDBusConnection)(LibHalContext *, DBusConnection *); 54 54 extern dbus_bool_t (*gLibHalCtxInit)(LibHalContext *, DBusError *); 55 extern char **(*gLibHalFindDeviceByCapability)(LibHalContext *, const char *, int *, DBusError *); 55 extern char **(*gLibHalFindDeviceStringMatch)(LibHalContext *, const char *, const char *, int *, 56 DBusError *); 56 57 extern char *(*gLibHalDeviceGetPropertyString)(LibHalContext *, const char *, const char *, 57 58 DBusError *); -
trunk/src/VBox/Main/linux/vbox-libhal.cpp
r4071 r5368 47 47 dbus_bool_t (*gLibHalCtxSetDBusConnection)(LibHalContext *, DBusConnection *); 48 48 dbus_bool_t (*gLibHalCtxInit)(LibHalContext *, DBusError *); 49 char **(*gLibHalFindDeviceByCapability)(LibHalContext *, const char *, int *, DBusError *); 49 char **(*gLibHalFindDeviceStringMatch)(LibHalContext *, const char *, const char *, int *, 50 DBusError *); 50 51 char *(*gLibHalDeviceGetPropertyString)(LibHalContext *, const char *, const char *, DBusError *); 51 52 void (*gLibHalFreeString)(char *); … … 79 80 (void **) &gLibHalCtxSetDBusConnection)) 80 81 && RT_SUCCESS(RTLdrGetSymbol(hLibHal, "libhal_ctx_init", (void **) &gLibHalCtxInit)) 81 && RT_SUCCESS(RTLdrGetSymbol(hLibHal, "libhal_ find_device_by_capability",82 (void **) &gLibHalFindDevice ByCapability))82 && RT_SUCCESS(RTLdrGetSymbol(hLibHal, "libhal_manager_find_device_string_match", 83 (void **) &gLibHalFindDeviceStringMatch)) 83 84 && RT_SUCCESS(RTLdrGetSymbol(hLibHal, "libhal_device_get_property_string", 84 85 (void **) &gLibHalDeviceGetPropertyString))
Note:
See TracChangeset
for help on using the changeset viewer.