MCPcopy Create free account
hub / github.com/apache/trafficserver / callConstructor

Method callConstructor

src/tscore/Extendible.cc:98–113  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

96 }
97
98 void
99 Schema::callConstructor(uintptr_t ext_loc)
100 {
101 ink_assert(ext_loc);
102 ++cnt_fld_constructed; // don't allow schema modification
103 ink_assert(cnt_fld_constructed <= cnt_constructed);
104
105 // init all extendible memory to 0, in case constructors don't
106 memset(reinterpret_cast<void *>(ext_loc), 0, alloc_size);
107
108 for (auto const &elm : fields) {
109 if (elm.second.constructor) {
110 elm.second.constructor(FieldPtr(ext_loc + elm.second.field_offset));
111 }
112 }
113 }
114
115 void
116 Schema::callDestructor(uintptr_t ext_loc)

Callers 1

initFieldsMethod · 0.80

Calls 1

memsetFunction · 0.85

Tested by

no test coverage detected