MCPcopy Create free account
hub / github.com/SeeFlowerX/stackplz / update_map

Method update_map

user/module/syscall.go:174–186  ·  view source on GitHub ↗
(map_name string, filter_key uint32, filter_value interface{})

Source from the content-addressed store, hash-verified

172}
173
174func (this *MSyscall) update_map(map_name string, filter_key uint32, filter_value interface{}) {
175 bpf_map, err := this.FindMap(map_name)
176 if err != nil {
177 panic(fmt.Sprintf("find [%s] failed, err:%v", map_name, err))
178 }
179 err = bpf_map.Update(unsafe.Pointer(&filter_key), filter_value, ebpf.UpdateAny)
180 if err != nil {
181 panic(fmt.Sprintf("update [%s] failed, err:%v", map_name, err))
182 }
183 if this.mconf.Debug {
184 this.logger.Printf("update %s success", map_name)
185 }
186}
187
188func (this *MSyscall) update_base_config() {
189 // 更新 base_config 用作基础的过滤 比如排除 stackplz 自身相关的调用

Callers 3

update_base_configMethod · 0.95
update_common_filterMethod · 0.95
update_child_parentMethod · 0.95

Calls 1

FindMapMethod · 0.95

Tested by

no test coverage detected