libthr: use nitems() for mib length
(cherry picked from commit ebf7a01594eeb8c2897d1b310069df35da112413)