From 633dc6f80f201afdf5b8524ae377187d58f0ef3b Mon Sep 17 00:00:00 2001 From: David Sterba Date: Tue, 12 Jan 2016 11:20:18 +0100 Subject: btrfs-progs: remove unnecessary errno temp variables We can read errno directly if it's not clobbered by any intermediate calls. Signed-off-by: David Sterba --- qgroup.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'qgroup.c') diff --git a/qgroup.c b/qgroup.c index f56f51a0..a672ac04 100644 --- a/qgroup.c +++ b/qgroup.c @@ -1050,7 +1050,6 @@ static int __qgroups_search(int fd, struct qgroup_lookup *qgroup_lookup) struct btrfs_ioctl_search_header *sh; unsigned long off = 0; unsigned int i; - int e; struct btrfs_qgroup_info_item *info; struct btrfs_qgroup_limit_item *limit; struct btrfs_qgroup *bq; @@ -1075,11 +1074,10 @@ static int __qgroups_search(int fd, struct qgroup_lookup *qgroup_lookup) while (1) { ret = ioctl(fd, BTRFS_IOC_TREE_SEARCH, &args); - e = errno; if (ret < 0) { fprintf(stderr, "ERROR: can't perform the search - %s\n", - strerror(e)); + strerror(errno)); return ret; } /* the ioctl returns the number of item it found in nr_items */ -- cgit v1.2.3