Skip to content

Commit

Permalink
Fix some more typos (#1084)
Browse files Browse the repository at this point in the history
  • Loading branch information
pmeerw authored Aug 2, 2024
1 parent b29613f commit 42df496
Show file tree
Hide file tree
Showing 14 changed files with 22 additions and 22 deletions.
2 changes: 1 addition & 1 deletion api/python/examples/authenticode/api_example.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@
# Get the certificate used by the signer
cert_signer = pe.signatures[0].signers[0].cert
print(cert_signer)
bin_ca.verify(cert_signer) # Verify that cert_signer is signed the the CA
bin_ca.verify(cert_signer) # Verify that cert_signer is signed the CA

# running with:
# LIEF_CA_BUNDLE=signify/signify/certs/authenticode-bundle.pem python ./authenticode.py avast_free_antivirus_setup_online.exe
Expand Down
2 changes: 1 addition & 1 deletion api/python/examples/authenticode/authenticode_reader.py
Original file line number Diff line number Diff line change
Expand Up @@ -203,7 +203,7 @@ def main():

parser.add_argument('-H', '--hash',
action='store_true', dest='show_hash',
help='Show the autentihash value')
help='Show the authentihash value')

parser.add_argument('-C', '--check',
action='store_true', dest='check_sig',
Expand Down
2 changes: 1 addition & 1 deletion api/python/src/DWARF/types/pyBase.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ void create<dw::types::Base>(nb::module_& m) {
type
.def_prop_ro("encoding", &dw::types::Base::encoding,
R"doc(
Describe how the the base type is encoded and should be interpreted.
Describe how the base type is encoded and should be interpreted.
)doc"_doc
)
;
Expand Down
2 changes: 1 addition & 1 deletion api/python/src/ELF/objects/pyNote.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,7 @@ void create<Note>(nb::module_& m) {
R"doc(
Return the original `NT_` value of the note.
This value should be interpreted according the the :attr:`~.name` of the
This value should be interpreted according the :attr:`~.name` of the
note.
)doc"_doc)

Expand Down
2 changes: 1 addition & 1 deletion api/python/src/PDB/types/pyClassLike.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ void create<pdb::types::ClassLike>(nb::module_& m) {

.def_prop_ro("size", &pdb::types::ClassLike::size,
R"doc(
Size of the the type including all its attributes. This size should match
Size of the type including all its attributes. This size should match
the ``sizeof(...)`` this type.
)doc"_doc
)
Expand Down
2 changes: 1 addition & 1 deletion api/rust/cargo/lief/src/dwarf/types/base.rs
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ impl FromFFI<ffi::DWARF_types_Base> for Base<'_> {
}

impl Base<'_> {
/// Describe how the the base type is encoded and should be interpreted
/// Describe how the base type is encoded and should be interpreted
pub fn encoding(&self) -> Encoding {
Encoding::from(self.ptr.encoding())
}
Expand Down
2 changes: 1 addition & 1 deletion api/rust/cargo/lief/src/elf/header.rs
Original file line number Diff line number Diff line change
Expand Up @@ -290,7 +290,7 @@ impl Header<'_> {
self.ptr.program_header_size()
}

/// Return the the number of segments
/// Return the number of segments
pub fn numberof_segments(&self) -> u32 {
self.ptr.numberof_segments()
}
Expand Down
2 changes: 1 addition & 1 deletion api/rust/cargo/lief/src/pdb/types/classlike.rs
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ pub trait ClassLike {
self.get_classlike().name().to_string()
}

/// Size of the the type including all its attributes. This size should match
/// Size of the type including all its attributes. This size should match
/// the `sizeof(...)` this type.
fn size(&self) -> u64 {
self.get_classlike().size()
Expand Down
6 changes: 3 additions & 3 deletions cmake/LIEFOptions.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ option(LIEF_EXTRA_WARNINGS "Enable extra warning from the compiler"
option(LIEF_LOGGING "Enable logging" ON)
option(LIEF_LOGGING_DEBUG "Enable debug logging" ON)
option(LIEF_ENABLE_JSON "Enable JSON-related APIs" ON)
option(LIEF_OPT_NLOHMANN_JSON_EXTERNAL "Use nlohmann/json externaly" OFF)
option(LIEF_OPT_NLOHMANN_JSON_EXTERNAL "Use nlohmann/json externally" OFF)
option(LIEF_FORCE_API_EXPORTS "Force exports of API symbols" OFF)
option(LIEF_PY_LIEF_EXT "Use a pre-installed version of LIEF for the bindings" OFF)
option(LIEF_RUST_API "Generate the C++ bridge for Rust's cxx" OFF)
Expand All @@ -41,7 +41,7 @@ cmake_dependent_option(LIEF_PYTHON_STATIC "Internal usage" OFF
"LIEF_PYTHON_API" OFF)

# OAT support relies on the ELF and DEX format.
# Therefore, these options must be enabled to support use this format
# Therefore, these options must be enabled to support this format
cmake_dependent_option(LIEF_OAT "Build LIEF with OAT module" ON
"LIEF_ELF;LIEF_DEX" OFF)

Expand Down Expand Up @@ -70,7 +70,7 @@ cmake_dependent_option(LIEF_INSTALL_COMPILED_EXAMPLES "Install LIEF Compiled exa
option(LIEF_EXTERNAL_SPDLOG OFF)

# This option enables to provide an external
# version of TartanLlama/expected (e.g. present on the system)
# version of TartanLlama/expected (e.g. present on the system)
option(LIEF_OPT_EXTERNAL_EXPECTED OFF)

# This option enables to provide an external version of utf8cpp
Expand Down
2 changes: 1 addition & 1 deletion include/LIEF/DWARF/types/Base.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ class LIEF_API Base : public Type {
return type->kind() == Type::KIND::BASE;
}

/// Describe how the the base type is encoded and should be interpreted
/// Describe how the base type is encoded and should be interpreted
ENCODING encoding() const;

~Base() override;
Expand Down
2 changes: 1 addition & 1 deletion include/LIEF/ELF/Header.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -176,7 +176,7 @@ class LIEF_API Header : public Object {
return program_header_size_;
}

/// Return the the number of segments
/// Return the number of segments
uint32_t numberof_segments() const {
return numberof_segments_;
}
Expand Down
2 changes: 1 addition & 1 deletion include/LIEF/PDB/types/ClassLike.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ class LIEF_API ClassLike : public Type {
/// Iterator over the different methods implemented in this class-type type
methods_iterator methods() const;

/// Size of the the type including all its attributes. This size should match
/// Size of the type including all its attributes. This size should match
/// the `sizeof(...)` this type.
uint64_t size() const;

Expand Down
2 changes: 1 addition & 1 deletion src/PE/Binary.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -671,7 +671,7 @@ uint32_t Binary::predict_function_rva(const std::string& library, const std::str
}


// We assume the the idata section will be the last section
// We assume the idata section will be the last section
const auto section_align = static_cast<uint64_t>(optional_header().section_alignment());
const uint64_t next_virtual_address = align(std::accumulate(
std::begin(sections_),
Expand Down
14 changes: 7 additions & 7 deletions src/PE/Builder.tcc
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ template<typename PE_T>
void Builder::build_import_table() {
using uint__ = typename PE_T::uint;

// Compute size of the the diffrent (sub)sections
// Compute size of the different (sub)sections
// inside the future import section
// ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Expand All @@ -112,10 +112,10 @@ void Builder::build_import_table() {
// Size of import entries
uint32_t entries_size = 0;

// Size of the section which will holds imported functions names
// Size of the section which will hold the imported functions names
uint32_t functions_name_size = 0;

// Size of the section which will holds library name (e.g. kernel32.dll)
// Size of the section which will hold the library name (e.g. kernel32.dll)
uint32_t libraries_name_size = 0;

// Size of the trampoline section
Expand All @@ -137,10 +137,10 @@ void Builder::build_import_table() {
trampolines_size += import.entries().size() * trampoline_size;
}

// Offset of the diffrents sections inside *import section*
// Offset of the different sections inside *import section*
// ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

// Offset to the import table (i.e list of pe_import)
// Offset to the import table (i.e. list of pe_import)
uint32_t import_table_offset = 0;

// Offset to the lookup table: After import table
Expand All @@ -149,10 +149,10 @@ void Builder::build_import_table() {
// Address table (IAT). Identical to the lookup table until the library is bound
uint32_t iat_offset = lookuptable_offset + entries_size / 2;

// Offset to the section which will contains hints/names of the imported functions name
// Offset to the section which will contain hints/names of the imported functions name
uint32_t functions_name_offset = iat_offset + entries_size / 2;

// Offset of the section which will holds libraries name
// Offset of the section which will hold libraries name
uint32_t libraries_name_offset = functions_name_offset + functions_name_size;

// Offset of the section where trampolines will be written
Expand Down

0 comments on commit 42df496

Please sign in to comment.