MCPcopy Create free account
hub / github.com/F-Stack/f-stack / trash_dtor

Function trash_dtor

freebsd/vm/uma_dbg.c:99–114  ·  view source on GitHub ↗

* Fills an item with predictable garbage * * Complies with standard dtor arg/return * */

Source from the content-addressed store, hash-verified

97 *
98 */
99void
100trash_dtor(void *mem, int size, void *arg)
101{
102 int cnt;
103 uint32_t *p;
104
105#ifdef DEBUG_MEMGUARD
106 if (is_memguard_addr(mem))
107 return;
108#endif
109
110 cnt = size / sizeof(uma_junk);
111
112 for (p = mem; cnt > 0; cnt--, p++)
113 *p = uma_junk;
114}
115
116/*
117 * Fills an item with predictable garbage

Callers 4

mb_dtor_packFunction · 0.85
mb_zfini_packFunction · 0.85
trash_initFunction · 0.85
item_dtorFunction · 0.85

Calls 1

is_memguard_addrFunction · 0.85

Tested by

no test coverage detected