Search code examples
lwip

lwIP - Difference between tcp_alloc and tcp_new


I am using the lwIP library (version 1.4.1) with raw API.

What is the difference between tcp_alloc() and tcp_new() functions?


Solution

  • tcp_alloc is an internal function that's only meant for use within the lwIP library. tcp_new is part of lwIP's public API; it creates a new connection identifier (PCB).