summaryrefslogtreecommitdiffstats
path: root/usr.bin/cksum
diff options
context:
space:
mode:
authorse <se@FreeBSD.org>2013-05-23 20:57:20 +0000
committerse <se@FreeBSD.org>2013-05-23 20:57:20 +0000
commit5e9a14d6464f5bb381f1daa4a07b9698e1be16eb (patch)
tree712b2d1d3d7fe2956f3c85a07bce8dec224e5986 /usr.bin/cksum
parent856e81509cb58d5b02ef1de1c673efd7b8864e27 (diff)
downloadFreeBSD-src-5e9a14d6464f5bb381f1daa4a07b9698e1be16eb.zip
FreeBSD-src-5e9a14d6464f5bb381f1daa4a07b9698e1be16eb.tar.gz
Fix target selection logic, which did not comply with the man page.
Instead of using the file with the least order of path name components, shortest filename and finally the shortest basename (with the search stopping as soon as one of these conditions is true), the first filename checked was used as the reference, and another filename was only selected if all of the above comparisons are in favour of the latter file. This was wrong, because filenames with path less components were only considered, if both of the other conditions were true as well. In fact, the first filename to be checked had good chances to be selected in the end, since it only needed to be better with regard to any one of the three criteria ... Reviewed by: delphij@freebsd.org
Diffstat (limited to 'usr.bin/cksum')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud