Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 15 Sep 2017 19:18:20 +0000
From:      bugzilla-noreply@freebsd.org
To:        freebsd-ports-bugs@FreeBSD.org
Subject:   [Bug 222312] sysutils/monit - filesystem statistics error
Message-ID:  <bug-222312-13-XjNIFRVUm4@https.bugs.freebsd.org/bugzilla/>
In-Reply-To: <bug-222312-13@https.bugs.freebsd.org/bugzilla/>
References:  <bug-222312-13@https.bugs.freebsd.org/bugzilla/>

next in thread | previous in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D222312

--- Comment #2 from Stephan <elijah@gmx.de> ---
The log error gets generated in src/device/sysdep_FREEBSD.c @ line 115

the code expects @least one digit in the devicename, which is not the case =
for
'/dev/gpt/rootfs'


// Parse the device path like /dev/da0p2 into name:instance -> da:0
static boolean_t _parseDevice(const char *path, Device_T device) {
        const char *base =3D File_basename(path);
        for (int i =3D 0; base[i]; i++) {
                if (isdigit(*(base + i))) {
                        strncpy(device->key, base, i < sizeof(device->key) =
? i
: sizeof(device->key) - 1);
                        device->instance =3D Str_parseInt(base + i);
                        return true;
                }
        }
        LogError("filesystem statistics error -- cannot parse device '%s'\n=
",
path);
        return false;
}

--=20
You are receiving this mail because:
You are the assignee for the bug.=



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-222312-13-XjNIFRVUm4>