aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2024-01-15 23:59:57 -0500
committerMike Frysinger <vapier@gentoo.org>2024-01-15 23:59:57 -0500
commit857eaddab407db1577076a09206386bc62bfa4eb (patch)
tree3efa13282adf18d4f296b750a1fceafc6b6dfc18
parentdrop old __BOUNDS_CHECKING_ON support (diff)
downloadpax-utils-857eaddab407db1577076a09206386bc62bfa4eb.tar.gz
pax-utils-857eaddab407db1577076a09206386bc62bfa4eb.tar.bz2
pax-utils-857eaddab407db1577076a09206386bc62bfa4eb.zip
fix various typos found w/codespell
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
-rw-r--r--README.md2
-rw-r--r--dumpelf.c4
-rwxr-xr-xlddtree.sh8
-rw-r--r--macho.h4
-rw-r--r--paxelf.c2
-rw-r--r--paxldso.c2
-rw-r--r--porting.h2
-rw-r--r--pspax.c2
-rw-r--r--pyproject.toml10
-rw-r--r--scanelf.c6
-rw-r--r--scanmacho.c2
11 files changed, 27 insertions, 17 deletions
diff --git a/README.md b/README.md
index 99bbc3f..ec4bfe6 100644
--- a/README.md
+++ b/README.md
@@ -22,7 +22,7 @@ PaX helpers for people interested in that.
pax-utils uses a bog-standard meson-based build system. See `meson_options.txt`
for configuration options.
-You don't need PaX to use the pax-utils. Infact the only thing they
+You don't need PaX to use the pax-utils. In fact the only thing they
really have in common is that pax-utils was initially written to aid in
deploying PaX systems so it includes support for PT_PAX_FLAGS and the
deprecated but still in use EI_PAX flags. For more information about PaX
diff --git a/dumpelf.c b/dumpelf.c
index 1a469ea..c8f27e4 100644
--- a/dumpelf.c
+++ b/dumpelf.c
@@ -114,7 +114,7 @@ static void dumpelf(const elfobj *elf, size_t file_cnt)
break_out_shdr:
printf("},\n");
- /* finish the namespace struct and start the abitrary ones */
+ /* finish the namespace struct and start the arbitrary ones */
printf("\n.dyns = dumpedelf_dyn_%zu,\n", file_cnt);
printf("};\n");
@@ -538,7 +538,7 @@ static void usage(int status)
exit(status);
}
-/* parse command line arguments and preform needed actions */
+/* parse command line arguments and perform needed actions */
static void parseargs(int argc, char *argv[])
{
int flag;
diff --git a/lddtree.sh b/lddtree.sh
index dfa8d06..e0185f4 100755
--- a/lddtree.sh
+++ b/lddtree.sh
@@ -96,8 +96,8 @@ find_elf() {
read_ldso_conf() {
local line p
for p ; do
- # if the glob didnt match anything #360041,
- # or the files arent readable, skip it
+ # If the glob didn't match anything #360041,
+ # or the files aren't readable, skip it.
[[ -r ${p} ]] || continue
while read line ; do
case ${line} in
@@ -179,12 +179,12 @@ show_elf() {
# No need for leading comma w/my_allhits as we guarantee it always
# starts with one due to the way we append the value above.
[[ ${my_allhits}, == *,${lib},* ]] && continue
- # If the interp is being linked against directly, re-use the existing
+ # If the interp is being linked against directly, reuse the existing
# full path rather than perform a search for it. When systems symlink
# the interp to a diff location, we might locate a different path, and
# displaying both doesn't make sense as it doesn't match the runtime --
# the ldso won't load another copy of ldso into memory from the search
- # path, it'll re-use the existing copy that was loaded from the full
+ # path, it'll reuse the existing copy that was loaded from the full
# hardcoded path.
if [[ ${lib} == "${interp}" ]] ; then
rlib=${full_interp}
diff --git a/macho.h b/macho.h
index 76f3697..4a99e8f 100644
--- a/macho.h
+++ b/macho.h
@@ -73,7 +73,7 @@ struct mach_header
incremental link against a base file and
cannot be link edited again */
#define MH_DYLDLINK 0x4 /* the object file is input for the dynamic
- linker and cannot be staticly link edited
+ linker and cannot be statically link edited
again */
#define MH_TWOLEVEL 0x80 /* the image is using two-level namespace
bindings */
@@ -107,7 +107,7 @@ struct mach_header
they are not used by other
code */
#define MH_NOMULTIDEFS 0x200 /* this umbrella guarantees there are no
- multiple defintions of symbols in its
+ multiple definitions of symbols in its
subimages, as a result the two-level
namespace hints can always be used */
diff --git a/paxelf.c b/paxelf.c
index fb4160c..9a34ea4 100644
--- a/paxelf.c
+++ b/paxelf.c
@@ -584,7 +584,7 @@ free_elf_and_return:
/* check class and stuff */
if (!DO_WE_LIKE_ELF(elf->data)) {
- warn("we no likey %s: {%s,%s,%s,%s}",
+ warn("unknown ELF settings: %s: {%s,%s,%s,%s}",
filename,
get_elfeitype(EI_CLASS, elf->data[EI_CLASS]),
get_elfeitype(EI_DATA, elf->data[EI_DATA]),
diff --git a/paxldso.c b/paxldso.c
index a9bef1e..5363134 100644
--- a/paxldso.c
+++ b/paxldso.c
@@ -357,7 +357,7 @@ int ldso_config_load(const char *fname)
size_t x;
const char *gpath;
- /* re-use existing path buffer ... need to be creative */
+ /* Reuse existing path buffer ... need to be creative. */
if (path[8] != '/')
gpath = memcpy(path + 3, "/etc/", 5);
else
diff --git a/porting.h b/porting.h
index 3a544fa..61018fb 100644
--- a/porting.h
+++ b/porting.h
@@ -191,7 +191,7 @@
#endif
/*
- * propably will never be official added to the toolchain.
+ * Probably will never be officially added to the toolchain.
* But none the less we should try to get 0x65041580 reserved
*/
#ifndef PT_PAX_FLAGS
diff --git a/pspax.c b/pspax.c
index e79469d..1e3562d 100644
--- a/pspax.c
+++ b/pspax.c
@@ -491,7 +491,7 @@ static void usage(int status)
exit(status);
}
-/* parse command line arguments and preform needed actions */
+/* parse command line arguments and perform needed actions */
static void parseargs(int argc, char *argv[])
{
int flag;
diff --git a/pyproject.toml b/pyproject.toml
index e633a0a..d3ae4e0 100644
--- a/pyproject.toml
+++ b/pyproject.toml
@@ -12,6 +12,16 @@ line-length = 88
target-version = ["py38"]
+# https://github.com/codespell-project/codespell?tab=readme-ov-file#using-a-config-file
+[tool.codespell]
+# eles: We use variable name as short for "elements".
+# Ned: Author's name.
+ignore-words-list = "eles,ned"
+
+# Imported from glibc.
+skip = "elf.h"
+
+
# https://pycqa.github.io/isort/docs/configuration/options
[tool.isort]
py_version = "38"
diff --git a/scanelf.c b/scanelf.c
index d306316..1a6043e 100644
--- a/scanelf.c
+++ b/scanelf.c
@@ -761,7 +761,7 @@ static const char *scanelf_file_textrels(elfobj *elf, char *found_textrels, char
if (symtab_void && elf->phdr)
SCANELF_ELF_SIZED(SHOW_TEXTRELS);
if (!*found_textrels)
- warnf("ELF %s has TEXTREL markings but doesnt appear to have any real TEXTREL's !?", elf->filename);
+ warnf("ELF %s has TEXTREL markings but doesn't appear to have any real TEXTREL's !?", elf->filename);
return NULL;
}
@@ -1154,7 +1154,7 @@ static const char *scanelf_file_soname(elfobj *elf, char *found_soname)
* STV group: STV_DEFAULT:p STV_INTERNAL:i STV_HIDDEN:h STV_PROTECTED:P
* SHN group: SHN_UNDEF:u SHN_ABS:a SHN_COMMON:c {defined}:d
* The "defined" value in the SHN group does not correspond to a SHN_xxx define.
- * You can search for multiple symbols at once by seperating with a comma (",").
+ * You can search for multiple symbols at once by separating with a comma (",").
*
* Some examples:
* ELFs with a weak function "foo":
@@ -1963,7 +1963,7 @@ static void usage(int status)
exit(status);
}
-/* parse command line arguments and preform needed actions */
+/* parse command line arguments and perform needed actions */
#define do_pax_state(option, flag) \
if (islower(option)) { \
flags &= ~PF_##flag; \
diff --git a/scanmacho.c b/scanmacho.c
index b96cf44..f0351ff 100644
--- a/scanmacho.c
+++ b/scanmacho.c
@@ -658,7 +658,7 @@ static void usage(int status)
exit(status);
}
-/* parse command line arguments and preform needed actions */
+/* parse command line arguments and perform needed actions */
static int parseargs(int argc, char *argv[])
{
int i;