Bug 45897

Summary: /usr/bin/du option -h -k conflicts.
Product: Base System Reporter: ginga-freebsd
Component: binAssignee: freebsd-bugs (Nobody) <bugs>
Status: Closed FIXED    
Severity: Affects Only Me CC: ginga-freebsd
Priority: Normal    
Version: Unspecified   
Hardware: Any   
OS: Any   
Attachments:
Description Flags
file.diff
none
file.diff none

Description ginga-freebsd 2002-12-01 13:10:01 UTC
	/usr/bin/du 's option -h and -k conflicts when -k is added
	AFTER -h option. When -k option is provided after -h option,
	it reports half the amount of data.

How-To-Repeat: 	% mkdir /tmp/test
	% cd /tmp/test
	% dd if=/dev/zero of=foo count=100	# 5kB
	% ls -l foo
	-rw-r--r--  1 ginga  wheel  51200 Dec  1 21:59 foo
	% du -sk .
	51	.
	% du -skh .
	 51K	.	# right
	% du -shk .
	 26K	.	# wrong! (only 1/2 reported)
	%
Comment 1 ginga 2002-12-05 02:43:30 UTC
In Sun, Dec 01, 2002 at 05:10:01AM -0800,
FreeBSD-gnats-submit@FreeBSD.org wrote:
> http://www.freebsd.org/cgi/query-pr.cgi?pr=45897
> 
> >Category:       bin
> >Responsible:    freebsd-bugs
> >Synopsis:       /usr/bin/du option -h -k conflicts.
> >Arrival-Date:   Sun Dec 01 05:10:01 PST 2002

This problem was already fixed in the -current
(remained only for 4-stable branch).
Sorry for reporting already fixed problem...
-- 
ginga
Comment 2 Tom Rhodes freebsd_committer freebsd_triage 2002-12-12 16:35:12 UTC
State Changed
From-To: open->closed

I've completed the MFC (different patch).  Thanks for pointing this out!