MCPcopy Create free account
hub / github.com/Universal-Team/Universal-Updater / commitToFileThreadFunc

Function commitToFileThreadFunc

source/utils/download.cpp:108–118  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

106}
107
108static void commitToFileThreadFunc(void *args) {
109 LightEvent_Signal(&waitCommit);
110
111 while (true) {
112 LightEvent_Wait(&readyToCommit);
113 LightEvent_Clear(&readyToCommit);
114 if (killThread) threadExit(0);
115 writeError = !filecommit();
116 LightEvent_Signal(&waitCommit);
117 }
118}
119
120static size_t file_handle_data(char *ptr, size_t size, size_t nmemb, void *userdata) {
121 if (getAvailableSpace() < (u64)downloadTotal) return 0; // Out of space.

Callers

nothing calls this directly

Calls 1

filecommitFunction · 0.85

Tested by

no test coverage detected