mirror of
https://github.com/php/php-src.git
synced 2026-03-24 00:02:20 +01:00
Use ull integer suffix for bitwise logic (GH-19673)
If (brake->type+1) exeeds 30, we have undefined behavior and won't actually remove the relevant bit. See GH-19633
This commit is contained in:
@@ -1206,14 +1206,14 @@ PHPDBG_API void phpdbg_delete_breakpoint(zend_ulong num) /* {{{ */
|
||||
name = estrdup(brake->name);
|
||||
name_len = strlen(name);
|
||||
if (zend_hash_num_elements(&PHPDBG_G(bp)[type]) == 1) {
|
||||
PHPDBG_G(flags) &= ~(1<<(brake->type+1));
|
||||
PHPDBG_G(flags) &= ~(1ull<<(brake->type+1));
|
||||
}
|
||||
}
|
||||
break;
|
||||
|
||||
default: {
|
||||
if (zend_hash_num_elements(table) == 1) {
|
||||
PHPDBG_G(flags) &= ~(1<<(brake->type+1));
|
||||
PHPDBG_G(flags) &= ~(1ull<<(brake->type+1));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user