From da87dba81716adccec405470a76c8cc8b930aad8 Mon Sep 17 00:00:00 2001 From: Wahib Faizi Date: Thu, 12 Jun 2014 23:40:18 +0400 Subject: [PATCH] staging: usbip: usbip_host_driver.c: avoid assignment in if Fix coding style issue "do not use assignment in if condition" detected by checkpatch.pl in usbip_host_driver.c. Signed-off-by: Wahib Faizi Signed-off-by: Greg Kroah-Hartman --- drivers/staging/usbip/userspace/libsrc/usbip_host_driver.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/staging/usbip/userspace/libsrc/usbip_host_driver.c b/drivers/staging/usbip/userspace/libsrc/usbip_host_driver.c index 92caef7474c7..32b8f52ace21 100644 --- a/drivers/staging/usbip/userspace/libsrc/usbip_host_driver.c +++ b/drivers/staging/usbip/userspace/libsrc/usbip_host_driver.c @@ -47,7 +47,8 @@ static int32_t read_attr_usbip_status(struct usbip_usb_device *udev) snprintf(status_attr_path, SYSFS_PATH_MAX, "%s/usbip_status", udev->path); - if ((fd = open(status_attr_path, O_RDONLY)) < 0) { + fd = open(status_attr_path, O_RDONLY); + if (fd < 0) { err("error opening attribute %s", status_attr_path); return -1; } -- 2.34.1