diff options
author | Kent Overstreet <kent.overstreet@gmail.com> | 2017-03-01 01:45:15 -0900 |
---|---|---|
committer | Kent Overstreet <kent.overstreet@gmail.com> | 2017-03-09 09:14:11 -0900 |
commit | a17f7bcec7ed810a247c24e56229af8f43a9a6ae (patch) | |
tree | 1b2d60b21661bd2991324e3efaa83b3cdd87a783 /cmd_device.c | |
parent | 171ee48e57be78f4e95954c99851553fa523bf91 (diff) |
cmd_migrate
Diffstat (limited to 'cmd_device.c')
-rw-r--r-- | cmd_device.c | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/cmd_device.c b/cmd_device.c index 1c5208af..505fedc4 100644 --- a/cmd_device.c +++ b/cmd_device.c @@ -121,10 +121,7 @@ int cmd_device_show(int argc, char *argv[]) char *dev_name = basename(dirname(link)); - int fd = openat(dirfd(fs.sysfs), entry->d_name, O_RDONLY); - if (fd < 0) - die("couldn't open device %s: %s\n", - entry->d_name, strerror(errno)); + int fd = xopenat(dirfd(fs.sysfs), entry->d_name, O_RDONLY); devices[nr_devices] = fill_dev(strdup(dev_name), nr, fd); tiers[devices[nr_devices].tier]++; |