MCPcopy Create free account
hub / github.com/1a1a11a/libCacheSim / create_cache_obj_from_request

Function create_cache_obj_from_request

libCacheSim/cache/cacheObj.c:44–49  ·  view source on GitHub ↗

* create a cache_obj from request * @param req * @return */

Source from the content-addressed store, hash-verified

42 * @return
43 */
44cache_obj_t *create_cache_obj_from_request(const request_t *req) {
45 cache_obj_t *cache_obj = my_malloc(cache_obj_t);
46 memset(cache_obj, 0, sizeof(cache_obj_t));
47 if (req != NULL) copy_request_to_cache_obj(cache_obj, req);
48 return cache_obj;
49}
50
51/** remove the object from the built-in doubly linked list
52 *

Callers 4

LRUv0_insertFunction · 0.85
_move_into_new_tableFunction · 0.85
chained_hashtable_insertFunction · 0.85

Calls 1

Tested by

no test coverage detected