summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorYu Watanabe <watanabe.yu+github@gmail.com>2022-08-02 02:43:38 +0900
committerYu Watanabe <watanabe.yu+github@gmail.com>2022-08-02 02:43:38 +0900
commit5162b2a1c4fa35ea4c7abdd075f9a4df13ea4f0e (patch)
treee1e063fefc38d5d1853aaff7563006e0ba3ba266
parentbc4b9a7117b617341231be703b2ea3d0639ee9bf (diff)
downloadsystemd-5162b2a1c4fa35ea4c7abdd075f9a4df13ea4f0e.tar.gz
tree-wide: fix typo
-rw-r--r--man/systemd-sleep.conf.xml2
-rw-r--r--src/basic/math-util.h2
-rw-r--r--src/resolve/resolved-dns-transaction.c2
-rw-r--r--src/sleep/sleep.c2
-rw-r--r--src/test/test-copy.c2
-rw-r--r--tmpfiles.d/provision.conf2
6 files changed, 6 insertions, 6 deletions
diff --git a/man/systemd-sleep.conf.xml b/man/systemd-sleep.conf.xml
index 2f04ce84a1..8b9ddd6e7d 100644
--- a/man/systemd-sleep.conf.xml
+++ b/man/systemd-sleep.conf.xml
@@ -80,7 +80,7 @@
<listitem><para>A low power state where the system is initially suspended
(the state is stored in RAM) and then hibernated based on battery percentage
capacity. If the current battery capacity is higher than 5%, the system goes
- back to suspend for interval calculated using battery disharge rate per hour.
+ back to suspend for interval calculated using battery discharge rate per hour.
Battery discharge rate per hour is stored in a file which is created after
initial suspend-resume cycle. The value is calculated using battery decreasing
charge level a timespan. In case of manual wakeup before RTC alarm, the timespan
diff --git a/src/basic/math-util.h b/src/basic/math-util.h
index 125e0c6209..24023cd2be 100644
--- a/src/basic/math-util.h
+++ b/src/basic/math-util.h
@@ -9,6 +9,6 @@
* The argument must be a floating point, i.e. one of float, double, or long double. */
#define iszero_safe(x) (fpclassify(x) == FP_ZERO)
-/* To avoid x == y and triggering compile warning -Wfloat-equal. This retuns false if one of the argument is
+/* To avoid x == y and triggering compile warning -Wfloat-equal. This returns false if one of the argument is
* NaN or infinity. One of the argument must be a floating point. */
#define fp_equal(x, y) iszero_safe((x) - (y))
diff --git a/src/resolve/resolved-dns-transaction.c b/src/resolve/resolved-dns-transaction.c
index 47af540338..328913e1da 100644
--- a/src/resolve/resolved-dns-transaction.c
+++ b/src/resolve/resolved-dns-transaction.c
@@ -1920,7 +1920,7 @@ static int dns_transaction_make_packet_mdns(DnsTransaction *t) {
ancount = be16toh(DNS_PACKET_HEADER(p)->ancount);
}
- /* Then, create acctual packet. */
+ /* Then, create actual packet. */
p = dns_packet_unref(p);
r = dns_packet_new_query(&p, t->scope->protocol, 0, false);
if (r < 0)
diff --git a/src/sleep/sleep.c b/src/sleep/sleep.c
index a1905dbc27..ff6c71d61b 100644
--- a/src/sleep/sleep.c
+++ b/src/sleep/sleep.c
@@ -304,7 +304,7 @@ static int execute_s2h(const SleepConfig *sleep_config) {
assert(previous_discharge_rate != 0);
suspend_interval = usec_sub_unsigned(last_capacity * USEC_PER_HOUR / previous_discharge_rate, 30 * USEC_PER_MINUTE);
/* The previous discharge rate is stored in per hour basis so converted to minutes.
- * Substracted 30 minutes from the result to keep a buffer of 30 minutes before battery gets critical */
+ * Subtracted 30 minutes from the result to keep a buffer of 30 minutes before battery gets critical */
}
log_debug("Set timerfd wake alarm for %s", FORMAT_TIMESPAN(suspend_interval, USEC_PER_SEC));
/* Wake alarm for system with or without battery to hibernate or estimate discharge rate whichever is applicable */
diff --git a/src/test/test-copy.c b/src/test/test-copy.c
index 09e78b920e..4091b425d1 100644
--- a/src/test/test-copy.c
+++ b/src/test/test-copy.c
@@ -66,7 +66,7 @@ TEST(copy_tree_replace_file) {
assert_se(write_string_file(src, "bar bar", WRITE_STRING_FILE_CREATE) == 0);
assert_se(write_string_file(dst, "foo foo foo", WRITE_STRING_FILE_CREATE) == 0);
- /* The file exists- now overwite original contents, and test the COPY_REPLACE flag. */
+ /* The file exists- now overwrite original contents, and test the COPY_REPLACE flag. */
assert_se(copy_tree(src, dst, UID_INVALID, GID_INVALID, COPY_REFLINK) == -EEXIST);
diff --git a/tmpfiles.d/provision.conf b/tmpfiles.d/provision.conf
index 9a4783868f..a4d7aaf99b 100644
--- a/tmpfiles.d/provision.conf
+++ b/tmpfiles.d/provision.conf
@@ -7,7 +7,7 @@
# See tmpfiles.d(5) for details
-# Provision additional loging messages from credentials, if they are set. Note
+# Provision additional login messages from credentials, if they are set. Note
# that these lines are NOPs if the credentials are not set or if the files
# already exist.
f^ /etc/motd.d/50-provision.conf - - - - login.motd