mirror of
https://github.com/isc-projects/bind9.git
synced 2026-06-11 10:10:00 -04:00
Address infinite loop when processing $GENERATE
In nibble mode if the value to be converted was negative the parser
would loop forever. Process the value as an unsigned int instead
of as an int to prevent sign extension when shifting.
This was found by Eric Sesterhenn from X41.
(cherry picked from commit 371824f078)
This commit is contained in:
parent
1bc1fc5a18
commit
58efb2f740
1 changed files with 2 additions and 1 deletions
|
|
@ -626,7 +626,8 @@ static const char *hex = "0123456789abcdef0123456789ABCDEF";
|
|||
* counting the terminating NUL.
|
||||
*/
|
||||
static unsigned int
|
||||
nibbles(char *numbuf, size_t length, unsigned int width, char mode, int value) {
|
||||
nibbles(char *numbuf, size_t length, unsigned int width, char mode,
|
||||
unsigned int value) {
|
||||
unsigned int count = 0;
|
||||
|
||||
/*
|
||||
|
|
|
|||
Loading…
Reference in a new issue