Bug 45897 - /usr/bin/du option -h -k conflicts.
Summary: /usr/bin/du option -h -k conflicts.
Status: Closed FIXED
Alias: None
Product: Base System
Classification: Unclassified
Component: bin (show other bugs)
Version: Unspecified
Hardware: Any Any
: Normal Affects Only Me
Assignee: freebsd-bugs (Nobody)
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2002-12-01 13:10 UTC by ginga-freebsd
Modified: 2002-12-12 16:35 UTC (History)
1 user (show)

See Also:


Attachments
file.diff (318 bytes, patch)
2002-12-01 13:10 UTC, ginga-freebsd
no flags Details | Diff
file.diff (346 bytes, patch)
2002-12-01 13:10 UTC, ginga-freebsd
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
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!