[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH][RFC] Add compare subcommand for qemu-img
From: |
Paolo Bonzini |
Subject: |
Re: [Qemu-devel] [PATCH][RFC] Add compare subcommand for qemu-img |
Date: |
Thu, 02 Aug 2012 13:11:31 +0200 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:13.0) Gecko/20120615 Thunderbird/13.0.1 |
Il 02/08/2012 12:06, Miroslav Rezanina ha scritto:
>>> > > + qemu_progress_print(((float) nb_sectors /
>>> > > progress_base)*100, 100);
>> >
>> > qemu_progress_print(nb_sectors, over_sectors);
>> >
>> >
>> > Paolo
>> >
> This won't work. qemu_progress_print takes either (current_progress,0) or
> (progress_delta,progress_part) where all values are in percents - values in
> range (0,100). If we pass (nb_sectors,over_sectors) we get 100% thanks to the
> formula:
>
> nb_sectors / 100 * over_sectors
Uff, I admit I never understood qemu_progress_print. :)
Paolo