From 2678cb00d4cb5426c4e5b714338065d9d3323f7b Mon Sep 17 00:00:00 2001 From: Kate Hsuan Date: Tue, 7 Jan 2025 15:49:12 +0800 Subject: [PATCH] Fix trailing white space and end of file --- libupower-glib/up-client.c | 1 - libupower-glib/up-client.h | 1 - libupower-glib/up-device.h | 1 - libupower-glib/up-history-item.c | 1 - libupower-glib/up-history-item.h | 1 - libupower-glib/up-stats-item.c | 1 - libupower-glib/up-stats-item.h | 1 - libupower-glib/up-types.h | 1 - libupower-glib/upower.h | 1 - src/dummy/up-native.c | 1 - src/freebsd/up-acpi-native.c | 1 - src/freebsd/up-backend.c | 1 - src/freebsd/up-device-supply.h | 1 - src/freebsd/up-util.c | 1 - src/linux/integration-test.py | 4 ++-- src/linux/up-backend.c | 1 - src/linux/up-device-bluez.h | 1 - src/linux/up-device-hid.c | 2 +- src/linux/up-device-hid.h | 1 - src/linux/up-device-idevice.h | 1 - src/linux/up-device-supply.h | 1 - src/linux/up-device-wup.h | 1 - src/linux/up-enumerator-udev.c | 2 +- src/linux/up-input.h | 1 - src/linux/up-native.c | 1 - src/openbsd/up-backend.c | 1 - src/up-backend.h | 1 - src/up-config.c | 1 - src/up-device-battery.c | 2 +- src/up-device-list.c | 1 - src/up-device-list.h | 1 - src/up-history.c | 1 - src/up-history.h | 1 - src/up-native.h | 1 - src/up-polkit.c | 1 - src/up-polkit.h | 1 - src/up-self-test.c | 1 - 37 files changed, 5 insertions(+), 38 deletions(-) diff --git a/libupower-glib/up-client.c b/libupower-glib/up-client.c index 41e61ed..fac4101 100644 --- a/libupower-glib/up-client.c +++ b/libupower-glib/up-client.c @@ -716,4 +716,3 @@ up_client_new_finish (GAsyncResult *res, return g_task_propagate_pointer (G_TASK (res), error); } - diff --git a/libupower-glib/up-client.h b/libupower-glib/up-client.h index da6a5d4..9435dbd 100644 --- a/libupower-glib/up-client.h +++ b/libupower-glib/up-client.h @@ -103,4 +103,3 @@ gboolean up_client_get_on_battery (UpClient *client); G_END_DECLS #endif /* __UP_CLIENT_H */ - diff --git a/libupower-glib/up-device.h b/libupower-glib/up-device.h index 142d09b..9c7a965 100644 --- a/libupower-glib/up-device.h +++ b/libupower-glib/up-device.h @@ -94,4 +94,3 @@ const gchar *up_device_get_object_path (UpDevice *device); G_END_DECLS #endif /* __UP_DEVICE_H */ - diff --git a/libupower-glib/up-history-item.c b/libupower-glib/up-history-item.c index 8e0b89f..e87b8c0 100644 --- a/libupower-glib/up-history-item.c +++ b/libupower-glib/up-history-item.c @@ -352,4 +352,3 @@ up_history_item_new (void) { return UP_HISTORY_ITEM (g_object_new (UP_TYPE_HISTORY_ITEM, NULL)); } - diff --git a/libupower-glib/up-history-item.h b/libupower-glib/up-history-item.h index 0175cdf..679481c 100644 --- a/libupower-glib/up-history-item.h +++ b/libupower-glib/up-history-item.h @@ -69,4 +69,3 @@ gboolean up_history_item_set_from_string (UpHistoryItem *history_item, G_END_DECLS #endif /* __UP_HISTORY_ITEM_H */ - diff --git a/libupower-glib/up-stats-item.c b/libupower-glib/up-stats-item.c index 538a44a..95d4715 100644 --- a/libupower-glib/up-stats-item.c +++ b/libupower-glib/up-stats-item.c @@ -226,4 +226,3 @@ up_stats_item_new (void) { return UP_STATS_ITEM (g_object_new (UP_TYPE_STATS_ITEM, NULL)); } - diff --git a/libupower-glib/up-stats-item.h b/libupower-glib/up-stats-item.h index ee6c33c..7aa7815 100644 --- a/libupower-glib/up-stats-item.h +++ b/libupower-glib/up-stats-item.h @@ -61,4 +61,3 @@ void up_stats_item_set_accuracy (UpStatsItem *stats_item, G_END_DECLS #endif /* __UP_STATS_ITEM_H */ - diff --git a/libupower-glib/up-types.h b/libupower-glib/up-types.h index 4944854..d44c94e 100644 --- a/libupower-glib/up-types.h +++ b/libupower-glib/up-types.h @@ -139,4 +139,3 @@ UpDeviceLevel up_device_level_from_string (const gchar *level); G_END_DECLS #endif /* __UP_TYPES_H */ - diff --git a/libupower-glib/upower.h b/libupower-glib/upower.h index 60974cb..12c35aa 100644 --- a/libupower-glib/upower.h +++ b/libupower-glib/upower.h @@ -45,4 +45,3 @@ #undef __UPOWER_H_INSIDE__ #endif /* __UPOWER_H__ */ - diff --git a/src/dummy/up-native.c b/src/dummy/up-native.c index 3392f83..82de1a9 100644 --- a/src/dummy/up-native.c +++ b/src/dummy/up-native.c @@ -37,4 +37,3 @@ up_native_get_native_path (GObject *object) { return "/sys/dummy"; } - diff --git a/src/freebsd/up-acpi-native.c b/src/freebsd/up-acpi-native.c index eb58db5..8220a5a 100644 --- a/src/freebsd/up-acpi-native.c +++ b/src/freebsd/up-acpi-native.c @@ -228,4 +228,3 @@ static void up_acpi_native_get_property (GObject * object, guint property_id, GV break; } } - diff --git a/src/freebsd/up-backend.c b/src/freebsd/up-backend.c index 00bd7db..e40e2d6 100644 --- a/src/freebsd/up-backend.c +++ b/src/freebsd/up-backend.c @@ -383,4 +383,3 @@ up_backend_new (void) { return g_object_new (UP_TYPE_BACKEND, NULL); } - diff --git a/src/freebsd/up-device-supply.h b/src/freebsd/up-device-supply.h index 8717e01..f0b5253 100644 --- a/src/freebsd/up-device-supply.h +++ b/src/freebsd/up-device-supply.h @@ -52,4 +52,3 @@ GType up_device_supply_get_type (void); G_END_DECLS #endif /* __UP_DEVICE_SUPPLY_H__ */ - diff --git a/src/freebsd/up-util.c b/src/freebsd/up-util.c index c257946..ff99790 100644 --- a/src/freebsd/up-util.c +++ b/src/freebsd/up-util.c @@ -118,4 +118,3 @@ up_get_string_sysctl (GError **err, const gchar *format, ...) return g_strdup ("asdf"); #endif } - diff --git a/src/linux/integration-test.py b/src/linux/integration-test.py index 346c2af..28a6851 100755 --- a/src/linux/integration-test.py +++ b/src/linux/integration-test.py @@ -1643,7 +1643,7 @@ class Tests(dbusmock.DBusTestCase): " abrupt power loss due to battery exhaustion may lead to data" " corruption. The system will perform \"HybridSleep\" instead." " Use AllowRiskyCriticalPowerAction=true to enable support for" - " risky settings.", + " risky settings.", timeout=UP_DAEMON_ACTION_DELAY + 0.5) # simulate that battery has 1% (less than PercentageAction) @@ -1738,7 +1738,7 @@ class Tests(dbusmock.DBusTestCase): " abrupt power loss due to battery exhaustion may lead to data" " corruption. The system will perform \"HybridSleep\" instead." " Use AllowRiskyCriticalPowerAction=true to enable support for" - " risky settings.", + " risky settings.", timeout=UP_DAEMON_ACTION_DELAY + 0.5) diff --git a/src/linux/up-backend.c b/src/linux/up-backend.c index 86de605..3a8fd11 100644 --- a/src/linux/up-backend.c +++ b/src/linux/up-backend.c @@ -863,4 +863,3 @@ up_backend_new (void) { return g_object_new (UP_TYPE_BACKEND, NULL); } - diff --git a/src/linux/up-device-bluez.h b/src/linux/up-device-bluez.h index 3afa2ea..ef4cb50 100644 --- a/src/linux/up-device-bluez.h +++ b/src/linux/up-device-bluez.h @@ -52,4 +52,3 @@ void up_device_bluez_update (UpDeviceBluez *bluez, G_END_DECLS #endif /* __UP_DEVICE_BLUEZ_H__ */ - diff --git a/src/linux/up-device-hid.c b/src/linux/up-device-hid.c index 9237262..4f2a47b 100644 --- a/src/linux/up-device-hid.c +++ b/src/linux/up-device-hid.c @@ -218,7 +218,7 @@ up_device_hid_get_all_data (UpDeviceHid *hid) rinfo.report_type = rtype; rinfo.report_id = HID_REPORT_ID_FIRST; while (ioctl (hid->priv->fd, HIDIOCGREPORTINFO, &rinfo) >= 0) { - for (i = 0; i < rinfo.num_fields; i++) { + for (i = 0; i < rinfo.num_fields; i++) { memset (&finfo, 0, sizeof (finfo)); finfo.report_type = rinfo.report_type; finfo.report_id = rinfo.report_id; diff --git a/src/linux/up-device-hid.h b/src/linux/up-device-hid.h index 310acf7..8ac8b30 100644 --- a/src/linux/up-device-hid.h +++ b/src/linux/up-device-hid.h @@ -51,4 +51,3 @@ GType up_device_hid_get_type (void); G_END_DECLS #endif /* __UP_DEVICE_HID_H__ */ - diff --git a/src/linux/up-device-idevice.h b/src/linux/up-device-idevice.h index 2326337..3ec6a32 100644 --- a/src/linux/up-device-idevice.h +++ b/src/linux/up-device-idevice.h @@ -53,4 +53,3 @@ GType up_device_idevice_get_type (void); G_END_DECLS #endif /* __UP_DEVICE_IDEVICE_H__ */ - diff --git a/src/linux/up-device-supply.h b/src/linux/up-device-supply.h index e95a636..dace142 100644 --- a/src/linux/up-device-supply.h +++ b/src/linux/up-device-supply.h @@ -54,4 +54,3 @@ UpDeviceState up_device_supply_get_state (GUdevDevice *native); G_END_DECLS #endif /* __UP_DEVICE_SUPPLY_H__ */ - diff --git a/src/linux/up-device-wup.h b/src/linux/up-device-wup.h index da08893..2602d98 100644 --- a/src/linux/up-device-wup.h +++ b/src/linux/up-device-wup.h @@ -51,4 +51,3 @@ GType up_device_wup_get_type (void); G_END_DECLS #endif /* __UP_DEVICE_WUP_H__ */ - diff --git a/src/linux/up-enumerator-udev.c b/src/linux/up-enumerator-udev.c index 553f652..30c8b6d 100644 --- a/src/linux/up-enumerator-udev.c +++ b/src/linux/up-enumerator-udev.c @@ -68,7 +68,7 @@ device_parent_id (GUdevDevice *dev) /* Continue walk if the parent is a "hid" device */ if (g_strcmp0 (subsystem, "hid") == 0) { /* if the parent is under /sys/devices/virtual/misc/uhid, the device should be input devices - * and return the path immediately to make sure they belongs to the correct parent. + * and return the path immediately to make sure they belongs to the correct parent. * for example: * root@fedora:/sys/devices/virtual/misc/uhid# ls * 0005:046D:B01A.0005 0005:05AC:0250.000B dev power subsystem uevent */ diff --git a/src/linux/up-input.h b/src/linux/up-input.h index 3229be1..604ae87 100644 --- a/src/linux/up-input.h +++ b/src/linux/up-input.h @@ -39,4 +39,3 @@ gboolean up_input_get_switch_value (UpInput *input); G_END_DECLS #endif /* __UP_INPUT_H__ */ - diff --git a/src/linux/up-native.c b/src/linux/up-native.c index 5896dad..7c31a8b 100644 --- a/src/linux/up-native.c +++ b/src/linux/up-native.c @@ -59,4 +59,3 @@ up_native_get_native_path (GObject *object) * fallback for completeness */ return g_udev_device_get_sysfs_path (device); } - diff --git a/src/openbsd/up-backend.c b/src/openbsd/up-backend.c index a4a607e..9e11035 100644 --- a/src/openbsd/up-backend.c +++ b/src/openbsd/up-backend.c @@ -685,4 +685,3 @@ up_backend_finalize (GObject *object) G_OBJECT_CLASS (up_backend_parent_class)->finalize (object); } - diff --git a/src/up-backend.h b/src/up-backend.h index 2f38393..90531d9 100644 --- a/src/up-backend.h +++ b/src/up-backend.h @@ -78,4 +78,3 @@ int up_backend_inhibitor_lock_take (UpBackend *backend, G_END_DECLS #endif /* __UP_BACKEND_H */ - diff --git a/src/up-config.c b/src/up-config.c index 932803d..c80105f 100644 --- a/src/up-config.c +++ b/src/up-config.c @@ -183,4 +183,3 @@ up_config_new (void) } return UP_CONFIG (up_config_object); } - diff --git a/src/up-device-battery.c b/src/up-device-battery.c index 5e7cb55..65f6941 100644 --- a/src/up-device-battery.c +++ b/src/up-device-battery.c @@ -259,7 +259,7 @@ up_device_battery_report (UpDeviceBattery *self, /* QUIRK: * * There is an old bug where some Lenovo machine switched from reporting - * energy to reporting charge numbers. The code used to react by + * energy to reporting charge numbers. The code used to react by * reloading everything, however, what apparently happens is that the * *energy* value simply starts being reported through *charge* * attributes. diff --git a/src/up-device-list.c b/src/up-device-list.c index 35a9999..af00894 100644 --- a/src/up-device-list.c +++ b/src/up-device-list.c @@ -212,4 +212,3 @@ up_device_list_new (void) { return g_object_new (UP_TYPE_DEVICE_LIST, NULL); } - diff --git a/src/up-device-list.h b/src/up-device-list.h index ebd5d9b..29c144d 100644 --- a/src/up-device-list.h +++ b/src/up-device-list.h @@ -65,4 +65,3 @@ GPtrArray *up_device_list_get_array (UpDeviceList *list); G_END_DECLS #endif /* __UP_DEVICE_LIST_H */ - diff --git a/src/up-history.c b/src/up-history.c index 0333feb..a9fa903 100644 --- a/src/up-history.c +++ b/src/up-history.c @@ -956,4 +956,3 @@ up_history_new (void) { return g_object_new (UP_TYPE_HISTORY, NULL); } - diff --git a/src/up-history.h b/src/up-history.h index 7b0c2bd..d86d76b 100644 --- a/src/up-history.h +++ b/src/up-history.h @@ -91,4 +91,3 @@ void up_history_set_directory (UpHistory *history, G_END_DECLS #endif /* __UP_HISTORY_H */ - diff --git a/src/up-native.h b/src/up-native.h index ee4be79..c97b587 100644 --- a/src/up-native.h +++ b/src/up-native.h @@ -30,4 +30,3 @@ const gchar *up_native_get_native_path (GObject *object); G_END_DECLS #endif /* __UP_NATIVE_H__ */ - diff --git a/src/up-polkit.c b/src/up-polkit.c index 1ead7e7..112115e 100644 --- a/src/up-polkit.c +++ b/src/up-polkit.c @@ -190,4 +190,3 @@ up_polkit_new (void) { return UP_POLKIT (g_object_new (UP_TYPE_POLKIT, NULL)); } - diff --git a/src/up-polkit.h b/src/up-polkit.h index 34b486e..ed34ad2 100644 --- a/src/up-polkit.h +++ b/src/up-polkit.h @@ -70,4 +70,3 @@ gboolean up_polkit_is_allowed (UpPolkit *polkit, G_END_DECLS #endif /* __UP_POLKIT_H */ - diff --git a/src/up-self-test.c b/src/up-self-test.c index a60f5f2..a96b46f 100644 --- a/src/up-self-test.c +++ b/src/up-self-test.c @@ -320,4 +320,3 @@ main (int argc, char **argv) return g_test_run (); } -