MCPcopy Create free account
hub / github.com/DescentDevelopers/Descent3 / CountListItems

Function CountListItems

Descent3/list.cpp:124–132  ·  view source on GitHub ↗

Returns the number of items in a list

Source from the content-addressed store, hash-verified

122
123// Returns the number of items in a list
124int CountListItems(listnode **listp) {
125 listnode *node;
126 int count = 0;
127
128 for (node = *listp; node != NULL; node = node->next)
129 count++;
130
131 return count;
132}
133
134// returns a pointer the given item index in a list
135// Returns NULL if point not found

Callers 1

DestroyBSPNodeFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected