stack overflow

Recursive call disaster

A stack overflow occurs when a program exhausts its call stack—the memory structure tracking function calls and local variables.

This typically happens with runaway recursion, where a function keeps calling itself without reaching a stopping condition.

The error crashes the program: The recursive function caused a stack overflow.

Stack Overflow (capitalized) is also the popular Q&A website for programmers, named after this error.

Related
  • bufferProtective intermediate space
  • crashSudden violent impact
  • memoryMind's retention capacity
  • errorFault in communication
  • heapJumbled collection of items

exception · recursion · infinite recursion · programming · debug · rubber duck · segfault · coding · developers · questions · answers · reputation · upvote · forum · bugs · pointer · leak · array

Categories
Opposites
memory error type

stack overflowmemory leak

Unreturned allocated space

Family

stack, overflow, stacks, stacked, stacking, stacker, overflows, overflowed, overflowing

Familiarity
Top 500,000
Profile
Used worldwide · Timeless · Rated G