MCPcopy Create free account
hub / github.com/LemonOSProject/LemonOS / Dequeue

Method Dequeue

Kernel/include/net/networkadapter.h:31–37  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

29 virtual int GetLink() { return linkState; }
30 virtual int QueueSize() { return queue.get_length(); }
31 virtual NetworkPacket Dequeue() {
32 if(queue.get_length()) {
33 return queue.remove_at(0);
34 } else {
35 return {nullptr, 0};
36 }
37 }
38 virtual NetworkPacket DequeueBlocking() {
39 Scheduler::BlockCurrentThread(blocker, threadLock);
40

Callers

nothing calls this directly

Calls 2

get_lengthMethod · 0.45
remove_atMethod · 0.45

Tested by

no test coverage detected