MCPcopy Create free account
hub / github.com/Snapchat/KeyDB / startLoadingFile

Function startLoadingFile

src/rdb.cpp:2629–2635  ·  view source on GitHub ↗

Mark that we are loading in the global state and setup the fields * needed to provide loading stats. * 'filename' is optional and used for rdb-check on error */

Source from the content-addressed store, hash-verified

2627 * needed to provide loading stats.
2628 * 'filename' is optional and used for rdb-check on error */
2629void startLoadingFile(FILE *fp, const char* filename, int rdbflags) {
2630 struct stat sb;
2631 if (fstat(fileno(fp), &sb) == -1)
2632 sb.st_size = 0;
2633 rdbFileBeingLoaded = filename;
2634 startLoading(sb.st_size, rdbflags);
2635}
2636
2637/* Refresh the loading progress info */
2638void loadingProgress(off_t pos) {

Callers 4

rdbLoadFileFunction · 0.85
mainFunction · 0.85
redis_check_rdbFunction · 0.85
loadAppendOnlyFileFunction · 0.85

Calls 1

startLoadingFunction · 0.85

Tested by

no test coverage detected