http://en.wikipedia.org/wiki/Infinite_loop
Looping
Looping is repeating a set of instructions until a specific condition is met. An infinite loop occurs when the condition will never be met, due to some inherent characteristic of the loop. There are a few situations when this is desired behavior. For example, many
server programs such as
Internet or
database servers loop forever waiting for and servicing requests, though these may not be strictly considered infinite loops, because manual program termination still serves as a condition which exits the loop. Most often, the term is used for those situations when this is not the intended result; that is, when this is a
bug. Such errors are most common among novice programmers, but can be made by experienced programmers as well, and their causes can be quite subtle.
One common cause, for example, is that the programmer intends to iterate over a collection of items such as a
linked list, executing the loop code once for each item. Improperly formed links can create a
reference loop in the list, causing the code to continue forever because the program never reaches the end of the list.
