[patch] Move negative checks to util.c, from acpi.c (resend)

Danny Kukawka danny.kukawka at web.de
Sat Aug 20 11:01:09 PDT 2005


Hi,

I found a little problem with your patch for util.c. I think in the case if 
the computed percentage is bigger than 100% (e.g. 108%) we should furthermore 
give return 100% and not -1. 

The reason is, as always ;), ACPI on different machines. The related machines 
returns the first time of discharging a higher 'remaining capacity' then the 
'last full capacity'. For us it approved to return 100 % in this cases.

What you think?

Cheers,

Danny

 util.c |    2 +-
 1 files changed, 1 insertion(+), 1 deletion(-)


On Friday 19 August 2005 21:29, Richard Hughes wrote:
> On Fri, 2005-08-19 at 15:28 -0400, David Zeuthen wrote:
> > On Fri, 2005-08-19 at 19:38 +0100, Richard Hughes wrote:
> > > Done. Newest version attached.
> >
> > Go for it.
>
> Lol, cool. I'll give it a go. :-)
>
> Richard.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: hal-fix-util.c_percentage.diff
Type: text/x-diff
Size: 576 bytes
Desc: not available
Url : http://lists.freedesktop.org/archives/hal/attachments/20050820/26722bea/hal-fix-util.c_percentage-0001.bin


More information about the hal mailing list