udev-util: drop unused function udev_device_new_from_stat_rdev()

This commit is contained in:
Yu Watanabe
2018-08-23 04:57:39 +09:00
parent e156d24b0a
commit 05becb11e8
2 changed files with 0 additions and 24 deletions
-22
View File
@@ -37,25 +37,3 @@ int udev_parse_config(void) {
return 0;
}
int udev_device_new_from_stat_rdev(struct udev *udev, const struct stat *st, struct udev_device **ret) {
struct udev_device *nd;
char type;
assert(st);
assert(ret);
if (S_ISBLK(st->st_mode))
type = 'b';
else if (S_ISCHR(st->st_mode))
type = 'c';
else
return -ENOTTY;
nd = udev_device_new_from_devnum(udev, type, st->st_rdev);
if (!nd)
return -errno;
*ret = nd;
return 0;
}
-2
View File
@@ -11,5 +11,3 @@ DEFINE_TRIVIAL_CLEANUP_FUNC(struct udev_ctrl_connection*, udev_ctrl_connection_u
DEFINE_TRIVIAL_CLEANUP_FUNC(struct udev_ctrl_msg*, udev_ctrl_msg_unref);
int udev_parse_config(void);
int udev_device_new_from_stat_rdev(struct udev *udev, const struct stat *st, struct udev_device **ret);