From e3ba9cdc175f2cb66c5a0f94e9b577f03c71de51 Mon Sep 17 00:00:00 2001 From: Packit Service Date: Feb 24 2021 16:07:39 +0000 Subject: Apply patch 0031-libmultipath-fix-sysfs-dev_loss_tmo-parsing.patch patch_name: 0031-libmultipath-fix-sysfs-dev_loss_tmo-parsing.patch present_in_specfile: true location_in_specfile: 31 --- diff --git a/libmultipath/discovery.c b/libmultipath/discovery.c index ffec516..83a41a4 100644 --- a/libmultipath/discovery.c +++ b/libmultipath/discovery.c @@ -583,7 +583,7 @@ sysfs_set_rport_tmo(struct multipath *mpp, struct path *pp) struct udev_device *rport_dev = NULL; char value[16], *eptr; char rport_id[32]; - unsigned long long tmo = 0; + unsigned int tmo; int ret; sprintf(rport_id, "rport-%d:%d-%d", @@ -607,8 +607,8 @@ sysfs_set_rport_tmo(struct multipath *mpp, struct path *pp) "error %d", rport_id, -ret); goto out; } - tmo = strtoull(value, &eptr, 0); - if (value == eptr || tmo == ULLONG_MAX) { + tmo = strtoul(value, &eptr, 0); + if (value == eptr) { condlog(0, "%s: Cannot parse dev_loss_tmo " "attribute '%s'", rport_id, value); goto out;