Skip to content

Commit

Permalink
Use 1k blocks in the interface. Makes it easier for df -k users
Browse files Browse the repository at this point in the history
  • Loading branch information
steveschnepp committed May 21, 2010
1 parent a588508 commit 584da29
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions contrib/rtbtrace.pl
Expand Up @@ -15,9 +15,9 @@
$| = 1;

# Give the blocksize as first arg
my $nb_blocks = shift;
if (! $nb_blocks) {
die "Should give the number of blocks as first arg";
my $nb_blocks_1k = shift;
if (! $nb_blocks_1k) {
die "Should give the number of 1k blocks as first arg";
}

my $win = Curses::new();
Expand Down Expand Up @@ -72,7 +72,7 @@ sub draw
$rows --; # last row is status row

my $nb_chars = $columns * $rows;
my $blocks_per_char = int ($nb_blocks / $nb_chars) + 1;
my $blocks_per_char = int ($nb_blocks_1k * 2 / $nb_chars) + 1;

# Each frame we redraw everything
$win->clear();
Expand Down

0 comments on commit 584da29

Please sign in to comment.