Skip to content

Commit

Permalink
core: typos a/an
Browse files Browse the repository at this point in the history
  • Loading branch information
dilyanpalauzov authored and miconda committed Dec 16, 2022
1 parent c9ff301 commit 521bf3d
Show file tree
Hide file tree
Showing 14 changed files with 20 additions and 20 deletions.
2 changes: 1 addition & 1 deletion src/core/action.c
Expand Up @@ -920,7 +920,7 @@ int do_action(struct run_act_ctx* h, struct action* a, struct sip_msg* msg)
if (len){
if(crt+len>end) goto error_uri;
memcpy(crt,tmp,len);crt+=len;
user=1; /* we have an user field so mark it */
user=1; /* we have a user field so mark it */
}

if (a->type==SET_USERPASS_T) tmp=0;
Expand Down
4 changes: 2 additions & 2 deletions src/core/bit_scan.h
Expand Up @@ -79,7 +79,7 @@
#elif defined __CPU_x86 || defined __CPU_x86_64
/* no asm (e.g. no CC_GCC_LIKE_ASM) => debruijn for bit_scan_forward and
* br for bit_scan_reverse */
/* make sure debruijn an branch version are enabled */
/* make sure debruijn and branch version are enabled */
#ifndef BIT_SCAN_DEBRUIJN
#define BIT_SCAN_DEBRUIJN
#endif
Expand Down Expand Up @@ -117,7 +117,7 @@

#else /* __CPU_XXX */
/* default - like x86 no asm */
/* make sure debruijn an branch version are enabled */
/* make sure debruijn and branch version are enabled */
#ifndef BIT_SCAN_DEBRUIJN
#define BIT_SCAN_DEBRUIJN
#endif
Expand Down
2 changes: 1 addition & 1 deletion src/core/daemonize.c
Expand Up @@ -111,7 +111,7 @@ int daemon_status_pre_daemonize(void)



/** wait for an exit status to be send by daemon_status_send().
/** wait for an exit status to be sent by daemon_status_send().
* @param status - filled with the sent status (a char).
* @return 0 on success, -1 on error (e.g. process died before sending
* status, not initialized a.s.o.).
Expand Down
2 changes: 1 addition & 1 deletion src/core/dns_cache.c
Expand Up @@ -786,7 +786,7 @@ inline static struct dns_hash_entry* dns_cache_mk_bad_entry(str* name,



/* create a a/aaaa hash entry from a name and ip address
/* create an a/aaaa hash entry from a name and ip address
* returns 0 on error */
inline static struct dns_hash_entry* dns_cache_mk_ip_entry(str* name,
struct ip_addr* ip)
Expand Down
2 changes: 1 addition & 1 deletion src/core/io_wait.h
Expand Up @@ -257,7 +257,7 @@ static inline int kq_ev_change(io_wait_h* h, int fd, int filter, int flag,
BUG("kq_ev_change: kevent flush changes failed"
" (unexpected error): %s [%d]\n",
strerror(errno), errno);
/* ignore error even if it's not a EBADF/ENOENT */
/* ignore error even if it's not an EBADF/ENOENT */
/* one of the file descriptors is bad, probably already
closed => try to apply changes one-by-one */
for (r = 0; r < h->kq_nchanges; r++) {
Expand Down
2 changes: 1 addition & 1 deletion src/core/mem/dl_malloc.c
Expand Up @@ -1260,7 +1260,7 @@ extern void* sbrk(ptrdiff_t);
/* The bit mask value corresponding to MALLOC_ALIGNMENT */
#define CHUNK_ALIGN_MASK (MALLOC_ALIGNMENT - SIZE_T_ONE)

/* True if address a has acceptable alignment */
/* True if address A has acceptable alignment */
#define is_aligned(A) (((size_t)((A)) & (CHUNK_ALIGN_MASK)) == 0)

/* the number of bytes to offset an address to align it */
Expand Down
2 changes: 1 addition & 1 deletion src/core/parser/digest/digest.c
Expand Up @@ -61,7 +61,7 @@ static inline int new_credentials(struct hdr_field* _h)
* Return value -1 means that the function was unable to allocate
* memory and therefore the server should return Internal Server Error,
* not Bad Request in this case !
* Bad Request should be send when return value != -1
* Bad Request should be sent when return value != -1
*/
int parse_credentials(struct hdr_field* _h)
{
Expand Down
6 changes: 3 additions & 3 deletions src/core/parser/parse_content.h
Expand Up @@ -91,7 +91,7 @@ struct mime_type {


/*! \brief
* returns the accept values of a sip_msg as an null-terminated array
* returns the accept values of a sip_msg as a null-terminated array
* of integer
*/
#define get_accept(_msg_) ((int*)((_msg_)->accept->parsed))
Expand All @@ -109,7 +109,7 @@ int parse_accept_body(struct hdr_field* const hdr);

/*! \brief
* parse the body of the Accept header. It's values are also converted
* as an null-terminated array of ints.
* as a null-terminated array of ints.
* Returns: 1 : OK
* 0 : hdr not found
* -1 : error (parse error)
Expand All @@ -119,7 +119,7 @@ int parse_accept_hdr(struct sip_msg* const msg);

/*! \brief
* parse the body of a Content_-Length header. Also tries to recognize the
* type specified by this header (see th above defines).
* type specified by this header (see the above defines).
* Returns the first chr after the end of the header.
*/
char* parse_content_length(char* const buffer, const char* const end, int* const length);
Expand Down
2 changes: 1 addition & 1 deletion src/core/parser/sdp/sdp.c
Expand Up @@ -550,7 +550,7 @@ static int parse_sdp_session(str *sdp_body, int session_num, str *cnt_disp, sdp_
}

payload_attr = 0;
/* Let's figure out the atributes */
/* Let's figure out the attributes */
a1p = find_sdp_line(m1p, m2p, 'a');
a2p = a1p;
for (;;) {
Expand Down
4 changes: 2 additions & 2 deletions src/core/route.c
Expand Up @@ -232,7 +232,7 @@ int route_get(struct route_list* rt, char* name)
int i;

len=strlen(name);
/* check if exists an non empty*/
/* check if exists and non empty*/
e=str_hash_get(&rt->names, name, len);
if (e){
i=e->u.n;
Expand Down Expand Up @@ -261,7 +261,7 @@ int route_lookup(struct route_list* rt, char* name)
struct str_hash_entry* e;

len=strlen(name);
/* check if exists an non empty*/
/* check if exists and non empty*/
e=str_hash_get(&rt->names, name, len);
if (e){
return e->u.n;
Expand Down
4 changes: 2 additions & 2 deletions src/core/rvalue.c
Expand Up @@ -2581,7 +2581,7 @@ struct rval_expr* mk_rval_expr_v(enum rval_type rv_type, void* val,


/**
* @brief Create a unary op. rval_expr
* @brief Create an unary op. rval_expr
* ret= op rve1
* @param op - rval expr. unary operator
* @param rve1 - rval expr. on which the operator will act.
Expand Down Expand Up @@ -3484,7 +3484,7 @@ static int rve_optimize(struct rval_expr* rve)
if (rve_replace_with_ct_rv(rve->right.rve, rv)<0)
goto error;
rve->op=RVE_IPLUS_OP;
LM_DBG("FIXUP RVE (%d,%d-%d,%d): optimized $v - a into "
LM_DBG("FIXUP RVE (%d,%d-%d,%d): optimized $v - an into "
"$v + (%d)\n",
rve->fpos.s_line, rve->fpos.s_col,
rve->fpos.e_line, rve->fpos.e_col,
Expand Down
2 changes: 1 addition & 1 deletion src/core/rvalue.h
Expand Up @@ -296,7 +296,7 @@ struct rval_expr* mk_rval_expr_v(enum rval_type rv_type, void* val,
struct cfg_pos* pos);

/**
* @brief Create a unary op. rval_expr
* @brief Create an unary op. rval_expr
* ret= op rve1
* @param op - rval expr. unary operator
* @param rve1 - rval expr. on which the operator will act.
Expand Down
2 changes: 1 addition & 1 deletion src/core/socket_info.c
Expand Up @@ -1763,7 +1763,7 @@ static int fix_hostname(str* name, struct ip_addr* address, str* address_str,
}

#ifdef USE_MCAST
/* Check if it is an multicast address and
/* Check if it is a multicast address and
* set the flag if so
*/
if (is_mcast(address)){
Expand Down
4 changes: 2 additions & 2 deletions src/core/ut.h
Expand Up @@ -659,15 +659,15 @@ static inline void strlower(str* _s)


/*
* Convert an str to unsigned long
* Convert a str to unsigned long
*/
static inline int str2ulong(str* _s, unsigned long* _r)
{
str2unval(_s, _r, long, ULONG_MAX);
}

/*
* Convert an str to unsigned integer
* Convert a str to unsigned integer
*/
static inline int str2int(str* _s, unsigned int* _r)
{
Expand Down

0 comments on commit 521bf3d

Please sign in to comment.