trivial: fix spelling in code comments
Based-on-patch-by: Rafael Fontenelle <rafaelff@gnome.org>
This commit is contained in:
committed by
Yu Watanabe
parent
213e759ad5
commit
f21f31b24b
@@ -114,7 +114,7 @@ bool strv_env_is_valid(char **e) {
|
||||
if (!env_assignment_is_valid(*p))
|
||||
return false;
|
||||
|
||||
/* Check if there are duplicate assginments */
|
||||
/* Check if there are duplicate assignments */
|
||||
k = strcspn(*p, "=");
|
||||
STRV_FOREACH(q, p + 1)
|
||||
if (strneq(*p, *q, k) && (*q)[k] == '=')
|
||||
@@ -388,7 +388,7 @@ int strv_env_replace(char ***l, char *p) {
|
||||
assert(p);
|
||||
|
||||
/* Replace first occurrence of the env var or add a new one in the
|
||||
* string list. Drop other occurences. Edits in-place. Does not copy p.
|
||||
* string list. Drop other occurrences. Edits in-place. Does not copy p.
|
||||
* p must be a valid key=value assignment.
|
||||
*/
|
||||
|
||||
|
||||
+1
-1
@@ -15,7 +15,7 @@
|
||||
* necessary to instantiate an object for each Hashmap use.
|
||||
*
|
||||
* If ENABLE_DEBUG_HASHMAP is defined (by configuring with --enable-debug=hashmap),
|
||||
* the implemention will:
|
||||
* the implementation will:
|
||||
* - store extra data for debugging and statistics (see tools/gdb-sd_dump_hashmaps.py)
|
||||
* - perform extra checks for invalid use of iterators
|
||||
*/
|
||||
|
||||
@@ -79,7 +79,7 @@ static int unhex_next(const char **p, size_t *l) {
|
||||
assert(l);
|
||||
|
||||
/* Find the next non-whitespace character, and decode it. We
|
||||
* greedily skip all preceeding and all following whitespace. */
|
||||
* greedily skip all preceding and all following whitespace. */
|
||||
|
||||
for (;;) {
|
||||
if (*l == 0)
|
||||
@@ -647,7 +647,7 @@ static int unbase64_next(const char **p, size_t *l) {
|
||||
assert(l);
|
||||
|
||||
/* Find the next non-whitespace character, and decode it. If we find padding, we return it as INT_MAX. We
|
||||
* greedily skip all preceeding and all following whitespace. */
|
||||
* greedily skip all preceding and all following whitespace. */
|
||||
|
||||
for (;;) {
|
||||
if (*l == 0)
|
||||
|
||||
@@ -570,7 +570,7 @@ int parse_fractional_part_u(const char **p, size_t digits, unsigned *res) {
|
||||
|
||||
s = *p;
|
||||
|
||||
/* accept any number of digits, strtoull is limted to 19 */
|
||||
/* accept any number of digits, strtoull is limited to 19 */
|
||||
for (i=0; i < digits; i++,s++) {
|
||||
if (*s < '0' || *s > '9') {
|
||||
if (i == 0)
|
||||
|
||||
@@ -425,7 +425,7 @@ int path_compare(const char *a, const char *b) {
|
||||
assert(a);
|
||||
assert(b);
|
||||
|
||||
/* A relative path and an abolute path must not compare as equal.
|
||||
/* A relative path and an absolute path must not compare as equal.
|
||||
* Which one is sorted before the other does not really matter.
|
||||
* Here a relative path is ordered before an absolute path. */
|
||||
d = (a[0] == '/') - (b[0] == '/');
|
||||
|
||||
@@ -425,7 +425,7 @@ int is_kernel_thread(pid_t pid) {
|
||||
q += l;
|
||||
}
|
||||
|
||||
/* Skip preceeding whitespace */
|
||||
/* Skip preceding whitespace */
|
||||
l = strspn(q, WHITESPACE);
|
||||
if (l < 1)
|
||||
return -EINVAL;
|
||||
|
||||
@@ -905,7 +905,7 @@ int parse_timestamp(const char *t, usec_t *usec) {
|
||||
* Otherwise just cut it off. */
|
||||
with_tz = !STR_IN_SET(tz, tzname[0], tzname[1]);
|
||||
|
||||
/* Cut off the timezone if we dont need it. */
|
||||
/* Cut off the timezone if we don't need it. */
|
||||
if (with_tz)
|
||||
t = strndupa(t, last_space - t);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user