A harvester (1), comprising a harvester aggregate (2) for felling, trimming and preparing tree trunks, a first measuring device (I) provided in connection with the harvester aggregate (2) for measuring of at least one dimension of a tree trunk. The harvester comprises a second measuring device (II) for measuring a feature of the first measuring device, whereby said feature is an attribute reflecting the capability of the first measuring device to measure said dimension correctly, and a control unit (11) configured to make a comparison between an actual value (a) of the measured feature and a target value (β) of said feature, whereby the target value is indicative of a state of the first measuring device, where its measurement of said dimension is considered to be correct.