hal: Branch 'master'
Richard Hughes
hughsient at kemper.freedesktop.org
Thu Jul 5 08:27:21 PDT 2007
hald/linux/device.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
New commits:
diff-tree 8652398da0134f5b4bf42564b6269b0c88dfd187 (from bed698872323c46fc6b44ffde10b1b2244b7e228)
Author: Richard Hughes <richard at hughsie.com>
Date: Thu Jul 5 16:25:12 2007 +0100
power_supply current is measured in ua not uw
diff --git a/hald/linux/device.c b/hald/linux/device.c
index a0a0b69..e64b108 100644
--- a/hald/linux/device.c
+++ b/hald/linux/device.c
@@ -2986,9 +2986,9 @@ refresh_battery_fast (HalDevice *d)
/* CURRENT: we prefer the average if it exists, although present is still pretty good */
if (hal_util_get_int_from_file (path, "current_avg", ¤t, 10)) {
- hal_device_property_set_int (d, "battery.current", current);
+ hal_device_property_set_int (d, "battery.current", current / 1000);
} else if (hal_util_get_int_from_file (path, "current_now", ¤t, 10)) {
- hal_device_property_set_int (d, "battery.current", current);
+ hal_device_property_set_int (d, "battery.current", current / 1000);
}
/* STATUS: Convert to charging/discharging state */
More information about the hal-commit
mailing list