summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorPaul Moore <paul@paul-moore.com>2020-08-22 10:49:37 -0400
committerPaul Moore <paul@paul-moore.com>2020-09-02 10:39:48 -0400
commit2693e416142bb5da10d74700595d69ddaae071cd (patch)
tree6e7907d1451e389d573bf11a6ef8cd05077b33b3 /src
parent00b858adc2866544d93af5d2d24086223e4363e8 (diff)
downloadlibseccomp-2693e416142bb5da10d74700595d69ddaae071cd.tar.gz
all: run ./tools/check-syntax over the code
This patch updates the code for the newly added spell checking. Reviewed-by: Tom Hromatka <tom.hromatka@oracle.com> Signed-off-by: Paul Moore <paul@paul-moore.com>
Diffstat (limited to 'src')
-rw-r--r--src/arch.c8
-rw-r--r--src/db.c4
-rw-r--r--src/gen_bpf.c12
-rw-r--r--src/system.h2
4 files changed, 13 insertions, 13 deletions
diff --git a/src/arch.c b/src/arch.c
index 5485eb8..73bf710 100644
--- a/src/arch.c
+++ b/src/arch.c
@@ -116,7 +116,7 @@ int arch_valid(uint32_t arch)
/**
* Lookup the architecture definition
- * @param token the architecure token
+ * @param token the architecture token
*
* Return the matching architecture definition, returns NULL on failure.
*
@@ -169,7 +169,7 @@ const struct arch_def *arch_def_lookup(uint32_t token)
/**
* Lookup the architecture definition by name
- * @param arch_name the architecure name
+ * @param arch_name the architecture name
*
* Return the matching architecture definition, returns NULL on failure.
*
@@ -328,8 +328,8 @@ const char *arch_syscall_resolve_num(const struct arch_def *arch, int num)
* @param arch the architecture definition
* @param syscall the syscall number
*
- * Translate the syscall number, in the context of the native architecure, to
- * the provided architecure. Returns zero on success, negative values on
+ * Translate the syscall number, in the context of the native architecture, to
+ * the provided architecture. Returns zero on success, negative values on
* failure.
*
*/
diff --git a/src/db.c b/src/db.c
index 836171a..2dc9733 100644
--- a/src/db.c
+++ b/src/db.c
@@ -1058,7 +1058,7 @@ int db_col_reset(struct db_filter_col *col, uint32_t def_action)
free(col->filters);
col->filters = NULL;
- /* set the endianess to undefined */
+ /* set the endianness to undefined */
col->endian = 0;
/* set the default attribute values */
@@ -1222,7 +1222,7 @@ int db_col_merge(struct db_filter_col *col_dst, struct db_filter_col *col_src)
unsigned int iter_a, iter_b;
struct db_filter **dbs;
- /* verify that the endianess is a match */
+ /* verify that the endianness is a match */
if (col_dst->endian != col_src->endian)
return -EDOM;
diff --git a/src/gen_bpf.c b/src/gen_bpf.c
index f7b6eca..6961d09 100644
--- a/src/gen_bpf.c
+++ b/src/gen_bpf.c
@@ -205,11 +205,11 @@ static struct bpf_blk *_hsh_remove(struct bpf_state *state, uint64_t h_val);
static struct bpf_blk *_hsh_find(const struct bpf_state *state, uint64_t h_val);
/**
- * Convert a 16-bit host integer into the target's endianess
+ * Convert a 16-bit host integer into the target's endianness
* @param arch the architecture definition
* @param val the 16-bit integer
*
- * Convert the endianess of the supplied value and return it to the caller.
+ * Convert the endianness of the supplied value and return it to the caller.
*
*/
static uint16_t _htot16(const struct arch_def *arch, uint16_t val)
@@ -221,11 +221,11 @@ static uint16_t _htot16(const struct arch_def *arch, uint16_t val)
}
/**
- * Convert a 32-bit host integer into the target's endianess
+ * Convert a 32-bit host integer into the target's endianness
* @param arch the architecture definition
* @param val the 32-bit integer
*
- * Convert the endianess of the supplied value and return it to the caller.
+ * Convert the endianness of the supplied value and return it to the caller.
*
*/
static uint32_t _htot32(const struct arch_def *arch, uint32_t val)
@@ -1303,7 +1303,7 @@ static inline bool _skip_syscall(struct bpf_state *state,
if (!syscall->valid)
return true;
- /* psuedo-syscalls should not be added to the filter unless explicity
+ /* psuedo-syscalls should not be added to the filter unless explicitly
* requested via SCMP_FLTATR_API_TSKIP
*/
if (((int)syscall->num < 0) &&
@@ -1662,7 +1662,7 @@ out:
* @param db_secondary the secondary DB
*
* Generate the BPF instruction block for the given filter DB(s)/architecture(s)
- * and return a pointer to the block on succes, NULL on failure. The resulting
+ * and return a pointer to the block on success, NULL on failure. The resulting
* block assumes that the architecture token has already been loaded into the
* BPF accumulator.
*
diff --git a/src/system.h b/src/system.h
index 096f3ca..b8c2bc9 100644
--- a/src/system.h
+++ b/src/system.h
@@ -91,7 +91,7 @@ struct seccomp_data {
/* rename some of the socket filter types to make more sense */
typedef struct sock_filter bpf_instr_raw;
-/* no new privs defintions */
+/* no new privs definitions */
#ifndef PR_SET_NO_NEW_PRIVS
#define PR_SET_NO_NEW_PRIVS 38
#endif