That for loop is a classic idiom for a non-terminating loop. It's what you use when you want a loop that never terminates, or whose termination is controlled by control flow statements inside the loop. The latter is the case here.
for(;;)
All parts of the for
loop are empty. They key to understanding why it is a non-terminating loop is the empty controlling expression in the for
statement.
The standard (6.8.5.3 The for statement) says, with my emphasis:
The statement
for ( clause-1 ; expression-2 ; expression-3 ) statement
behaves as follows: The expression expression-2 is the controlling
expression that is evaluated before each execution of the loop body.
The expression expression-3 is evaluated as a void expression after
each execution of the loop body. If clause-1 is a declaration, the
scope of any identifiers it declares is the remainder of the
declaration and the entire loop, including the other two expressions;
it is reached in the order of execution before the first evaluation of
the controlling expression. If clause-1 is an expression, it is
evaluated as a void expression before the first evaluation of the
controlling expression.158)
Both clause-1 and expression-3 can be omitted. An omitted
expression-2 is replaced by a nonzero constant.
And this means that your loop will never terminate due to the controlling expression part of the for
statement.