mirror of
https://github.com/AuxXxilium/eudev.git
synced 2024-12-28 06:35:34 +07:00
hwdb: allow to query arbitrary keys
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
This commit is contained in:
parent
36cac2c40f
commit
7a3bcc197c
@ -144,6 +144,13 @@ static int builtin_hwdb(struct udev_device *dev, int argc, char *argv[], bool te
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* query a specific key given as argument */
|
||||||
|
if (argv[optind]) {
|
||||||
|
if (udev_builtin_hwdb_lookup(dev, argv[optind], filter, test) > 0)
|
||||||
|
return EXIT_SUCCESS;
|
||||||
|
return EXIT_FAILURE;
|
||||||
|
}
|
||||||
|
|
||||||
/* read data from another device than the device we will store the data */
|
/* read data from another device than the device we will store the data */
|
||||||
if (device) {
|
if (device) {
|
||||||
srcdev = udev_device_new_from_device_id(udev_device_get_udev(dev), device);
|
srcdev = udev_device_new_from_device_id(udev_device_get_udev(dev), device);
|
||||||
|
Loading…
Reference in New Issue
Block a user