ascii-chat 0.8.38
Real-time terminal-based video chat with ASCII art conversion
Loading...
Searching...
No Matches
session.c File Reference

Go to the source code of this file.

Functions

void session_entry_destroy (session_entry_t *entry)
 Free a session entry and all its resources.
 

Function Documentation

◆ session_entry_destroy()

void session_entry_destroy ( session_entry_t *  entry)

Free a session entry and all its resources.

Parameters
entrySession entry to free

Definition at line 15 of file lib/discovery/session.c.

15 {
16 if (!entry) {
17 return;
18 }
19
20 // Free all participants
21 for (size_t i = 0; i < MAX_PARTICIPANTS; i++) {
22 if (entry->participants[i]) {
23 SAFE_FREE(entry->participants[i]);
24 }
25 }
26
27 // Free the entry itself
28 SAFE_FREE(entry);
29}
#define MAX_PARTICIPANTS
Definition session.h:33

References MAX_PARTICIPANTS.

Referenced by database_session_join(), signaling_broadcast(), signaling_relay_ice(), and signaling_relay_sdp().