VALUE *v;
v = xzalloc(sizeof(VALUE));
- if (INTEGER) /* otherwise xzaaloc did it already */
+ if (INTEGER) /* otherwise xzalloc did it already */
v->type = INTEGER;
v->u.i = i;
return v;
VALUE *v;
v = xzalloc(sizeof(VALUE));
- if (STRING) /* otherwise xzaaloc did it already */
+ if (STRING) /* otherwise xzalloc did it already */
v->type = STRING;
v->u.s = xstrdup(s);
return v;
#endif
#define ALLOCATED 1
#define COMPILED 2
- int flg_mem_alocated_compiled;
+ int flg_mem_allocated_compiled;
} grep_list_data_t;
#if !ENABLE_EXTRA_COMPAT
#endif
char *match_at;
- if (!(gl->flg_mem_alocated_compiled & COMPILED)) {
- gl->flg_mem_alocated_compiled |= COMPILED;
+ if (!(gl->flg_mem_allocated_compiled & COMPILED)) {
+ gl->flg_mem_allocated_compiled |= COMPILED;
#if !ENABLE_EXTRA_COMPAT
xregcomp(&gl->compiled_regex, gl->pattern, reflags);
#else
grep_list_data_t *gl = xzalloc(sizeof(*gl));
gl->pattern = pattern;
#if ENABLE_FEATURE_CLEAN_UP
- gl->flg_mem_alocated_compiled = flg_used_mem;
+ gl->flg_mem_allocated_compiled = flg_used_mem;
#else
- /*gl->flg_mem_alocated_compiled = 0;*/
+ /*gl->flg_mem_allocated_compiled = 0;*/
#endif
return (char *)gl;
}
grep_list_data_t *gl = (grep_list_data_t *)pattern_head_ptr->data;
pattern_head = pattern_head->link;
- if (gl->flg_mem_alocated_compiled & ALLOCATED)
+ if (gl->flg_mem_allocated_compiled & ALLOCATED)
free(gl->pattern);
- if (gl->flg_mem_alocated_compiled & COMPILED)
+ if (gl->flg_mem_allocated_compiled & COMPILED)
regfree(&gl->compiled_regex);
free(gl);
free(pattern_head_ptr);
* FIXME: this can allocate very large block on stack and SEGV.
* Example:
* echo "..<100kbytes>..`true` $(true) `true` ..."
- * alocates 100kb for every command subst. With about
+ * allocates 100kb for every command subst. With about
* a hundred command substitutions stack overflows.
* With larger prepended string, SEGV happens sooner.
*/