Skip to content

Commit 30a77bc

Browse files
Fix various typos
1 parent 98e0dbc commit 30a77bc

File tree

11 files changed

+22
-22
lines changed

11 files changed

+22
-22
lines changed

ext/gettext/gettext.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -194,7 +194,7 @@ PHP_FUNCTION(bindtextdomain)
194194
btd_result = bindtextdomain(ZSTR_VAL(domain), NULL);
195195
if (btd_result == NULL) {
196196
/* POSIX-compliant implementations can return
197-
* NULL if an error occured. On musl you will
197+
* NULL if an error occurred. On musl you will
198198
* also get NULL if the domain is not yet
199199
* bound, because musl has no default directory
200200
* to return in that case. */

ext/lexbor/lexbor/unicode/base.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -141,7 +141,7 @@ struct lxb_unicode_normalizer {
141141
lxb_unicode_buffer_t *ican;
142142

143143
lxb_char_t tmp[4];
144-
uint8_t tmp_lenght;
144+
uint8_t tmp_length;
145145

146146
uint8_t quick_ccc;
147147
lxb_unicode_quick_type_t quick_type;

ext/lexbor/lexbor/unicode/unicode.c

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,7 @@ lxb_unicode_normalizer_init(lxb_unicode_normalizer_t *uc,
103103
return status;
104104
}
105105

106-
uc->tmp_lenght = 0;
106+
uc->tmp_length = 0;
107107
uc->starter = NULL;
108108

109109
uc->buf = lexbor_malloc(buf_length * sizeof(lxb_unicode_buffer_t));
@@ -123,7 +123,7 @@ lxb_unicode_normalizer_init(lxb_unicode_normalizer_t *uc,
123123
void
124124
lxb_unicode_normalizer_clean(lxb_unicode_normalizer_t *uc)
125125
{
126-
uc->tmp_lenght = 0;
126+
uc->tmp_length = 0;
127127
uc->starter = NULL;
128128
uc->p = uc->buf;
129129
uc->ican = uc->buf;
@@ -328,7 +328,7 @@ lxb_unicode_restore(lxb_unicode_normalizer_t *uc, const lxb_char_t *data,
328328
lxb_char_t *tmp;
329329

330330
tmp = uc->tmp;
331-
len = uc->tmp_lenght;
331+
len = uc->tmp_length;
332332

333333
i = lxb_encoding_decode_utf_8_length(tmp[0]);
334334

@@ -341,14 +341,14 @@ lxb_unicode_restore(lxb_unicode_normalizer_t *uc, const lxb_char_t *data,
341341
tmp + i);
342342
if (*cp == LXB_ENCODING_DECODE_ERROR) {
343343
if (!is_last) {
344-
uc->tmp_lenght = len;
344+
uc->tmp_length = len;
345345
return NULL;
346346
}
347347

348348
*cp = LXB_ENCODING_REPLACEMENT_CODEPOINT;
349349
}
350350

351-
uc->tmp_lenght = 0;
351+
uc->tmp_length = 0;
352352

353353
return data;
354354
}
@@ -393,7 +393,7 @@ lxb_unicode_normalize_body(lxb_unicode_normalizer_t *uc, const void *data,
393393
length *= (is_cp) ? sizeof(lxb_codepoint_t) : 1;
394394
end = (const lxb_char_t *) data + length;
395395

396-
if (uc->tmp_lenght != 0 && !is_cp) {
396+
if (uc->tmp_length != 0 && !is_cp) {
397397
np = lxb_unicode_restore(uc, np, end, &cp, is_last);
398398
if (np == NULL) {
399399
return LXB_STATUS_OK;
@@ -410,9 +410,9 @@ lxb_unicode_normalize_body(lxb_unicode_normalizer_t *uc, const void *data,
410410
if (cp == LXB_ENCODING_DECODE_ERROR) {
411411
if (np >= end && !is_last) {
412412
uc->p = p;
413-
uc->tmp_lenght = end - tp;
413+
uc->tmp_length = end - tp;
414414

415-
memcpy(uc->tmp, tp, uc->tmp_lenght);
415+
memcpy(uc->tmp, tp, uc->tmp_length);
416416

417417
return LXB_STATUS_OK;
418418
}
@@ -530,7 +530,7 @@ lxb_unicode_quick_check(lxb_unicode_normalizer_t *uc, const lxb_char_t *data,
530530

531531
end = data + length;
532532

533-
if (uc->tmp_lenght != 0) {
533+
if (uc->tmp_length != 0) {
534534
data = lxb_unicode_restore(uc, data, end, &cp, is_last);
535535
if (data == NULL) {
536536
return LXB_STATUS_OK;
@@ -545,9 +545,9 @@ lxb_unicode_quick_check(lxb_unicode_normalizer_t *uc, const lxb_char_t *data,
545545
cp = lxb_encoding_decode_valid_utf_8_single(&data, end);
546546
if (cp == LXB_ENCODING_DECODE_ERROR) {
547547
if (data >= end && !is_last) {
548-
uc->tmp_lenght = end - tp;
548+
uc->tmp_length = end - tp;
549549

550-
memcpy(uc->tmp, tp, uc->tmp_lenght);
550+
memcpy(uc->tmp, tp, uc->tmp_length);
551551

552552
return LXB_STATUS_OK;
553553
}

ext/opcache/jit/ir/ir.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -409,7 +409,7 @@ typedef int32_t ir_ref;
409409
#define IR_CONSTS_LIMIT_MIN (-(IR_TRUE - 1))
410410
#define IR_INSNS_LIMIT_MIN (IR_UNUSED + 1)
411411

412-
/* ADDR_MEMBER is neccessary to workaround MSVC C preprocessor bug */
412+
/* ADDR_MEMBER is necessary to workaround MSVC C preprocessor bug */
413413
#ifndef IR_64
414414
# define ADDR_MEMBER uintptr_t addr; \
415415
void *ptr;

ext/opcache/jit/ir/ir_gcm.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -262,7 +262,7 @@ static bool ir_split_partially_dead_node(ir_ctx *ctx, ir_ref ref, uint32_t b)
262262
#endif
263263

264264
/* 1.2. Iteratively check the predecessors of already found TOTALLY_USEFUL blocks and
265-
* add them into TOTALLY_USEFUL set if all of their sucessors are already there.
265+
* add them into TOTALLY_USEFUL set if all of their successors are already there.
266266
*/
267267
IR_SPARSE_SET_FOREACH(&data->totally_useful, i) {
268268
_push_predecessors(ctx, &ctx->cfg_blocks[i], data);

ext/opcache/shared_alloc_mmap.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@
5252
#endif
5353

5454
#if defined(HAVE_JIT) && (defined(__linux__) || defined(__FreeBSD__)) && (defined(__x86_64__) || defined (__aarch64__)) && !defined(__SANITIZE_ADDRESS__)
55-
static void *find_prefered_mmap_base(size_t requested_size)
55+
static void *find_preferred_mmap_base(size_t requested_size)
5656
{
5757
size_t huge_page_size = 2 * 1024 * 1024;
5858
uintptr_t last_free_addr = huge_page_size;
@@ -204,7 +204,7 @@ static int create_segments(size_t requested_size, zend_shared_segment ***shared_
204204
void *hint;
205205
if (JIT_G(enabled) && JIT_G(buffer_size)
206206
&& zend_jit_check_support() == SUCCESS) {
207-
hint = find_prefered_mmap_base(requested_size);
207+
hint = find_preferred_mmap_base(requested_size);
208208
} else {
209209
/* Do not use a hint if JIT is not enabled, as this profits only JIT and
210210
* this is potentially unsafe when the only suitable candidate is just

ext/pcre/pcre2lib/pcre2_auto_possess.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1163,7 +1163,7 @@ leaving the remainder of the pattern unpossessified.
11631163
cb compile data block
11641164
11651165
Returns: 0 for success
1166-
-1 if a non-existant opcode is encountered
1166+
-1 if a non-existent opcode is encountered
11671167
*/
11681168

11691169
int

ext/pcre/pcre2lib/pcre2_internal.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1428,7 +1428,7 @@ end of a range, which started before the starting character of the
14281428
character list. */
14291429
#define XCL_BEGIN_WITH_RANGE 0x4
14301430
/* Number of items in the character list: 0, 1, or 2. The value 3
1431-
represents that the item count is stored at the begining of the
1431+
represents that the item count is stored at the beginning of the
14321432
character list. The item count has the same width as the items
14331433
in the character list (e.g. 16 bit for Low16 and High16 lists). */
14341434
#define XCL_ITEM_COUNT_MASK 0x3

ext/pcre/pcre2lib/pcre2_match.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -353,7 +353,7 @@ seems unlikely.)
353353
mb points to match block
354354
lengthptr pointer for returning the length matched
355355
356-
Returns: = 0 sucessful match; number of code units matched is set
356+
Returns: = 0 successful match; number of code units matched is set
357357
< 0 no match
358358
> 0 partial match
359359
*/

ext/pdo_mysql/php_pdo_mysql_int.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ ZEND_BEGIN_MODULE_GLOBALS(pdo_mysql)
7878
/* dummy member so we get at least one member in the struct
7979
* and avoids build errors.
8080
*/
81-
void *dummymemmber;
81+
void *dummymember;
8282
#endif
8383
ZEND_END_MODULE_GLOBALS(pdo_mysql)
8484

0 commit comments

Comments
 (0)