Re: [PATCH 5/8] sfdisk: fix silly mbyte typo

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 04/17/2012 03:14 PM, Bernhard Voelker wrote:
> On 04/17/2012 03:56 PM, Pádraig Brady wrote:
>> On 04/17/2012 09:42 AM, Bernhard Voelker wrote:
>>> Karel Zak wrote:
>>>
>>>> On Mon, Apr 16, 2012 at 12:22:12PM +0200, Voelker, Bernhard wrote:
>>>>> Maybe this is better?
>>>>>
>>>>> -	printf(_("Units = mebibytes of 1048576 bytes, blocks of 1024 bytes"
>>>>> +	printf(_("Units = 1MiB, blocks of 1024*1024 bytes"
>>
>> Blocks are 1024 bytes in this mode, as confirmed with:
>> sfdisk -uM -l /dev/sda
> 
> I don't understand. What's wrong?
> 
> $ wc -c </dev/sda1
> 12582912000
> 
> $ echo '12582912000 / (1024*1024)' | bc
> 12000
> 
> $ ./sfdisk -uM -l /dev/sda | egrep 'sda1|MiB'
> Units = 1MiB, blocks of 1024*1024 bytes, counting from 0
>    Device Boot Start   End    MiB    #blocks   Id  System
> /dev/sda1   *     1  12000  12000   12288000   83  Linux

Well I thought the "blocks of" was referring to the blocks column,
rather than the units?

$ echo $((12582912000 / 1024))
12288000

cheers,
Pádraig.
--
To unsubscribe from this list: send the line "unsubscribe util-linux" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Netdev]     [Ethernet Bridging]     [Linux Wireless]     [Kernel Newbies]     [Security]     [Linux for Hams]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux Admin]     [Samba]

  Powered by Linux