From a48308701a4d89d7cc0d0557cfabaec94a0bb3b0 Mon Sep 17 00:00:00 2001 From: Bernhard Reutner-Fischer Date: Mon, 26 Oct 2009 23:27:08 +0100 Subject: add and use xopen_nonblocking (-18b) Signed-off-by: Bernhard Reutner-Fischer Signed-off-by: Denys Vlasenko --- miscutils/hdparm.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'miscutils/hdparm.c') diff --git a/miscutils/hdparm.c b/miscutils/hdparm.c index 65c11ec79..c4d2f3b03 100644 --- a/miscutils/hdparm.c +++ b/miscutils/hdparm.c @@ -1552,8 +1552,8 @@ static void process_dev(char *devname) unsigned char args[4] = { WIN_SETFEATURES, 0, 0, 0 }; const char *fmt = " %s\t= %2ld"; - /*fd = xopen(devname, O_RDONLY | O_NONBLOCK);*/ - xmove_fd(xopen(devname, O_RDONLY | O_NONBLOCK), fd); + /*fd = xopen_nonblocking(devname);*/ + xmove_fd(xopen_nonblocking(devname), fd); printf("\n%s:\n", devname); if (getset_readahead == IS_SET) { -- cgit v1.2.3