Beispiel #1
0
func (u *uc) HookDel(hook Hook) error {
	if uptr, ok := hookToUintptr[hook]; ok {
		delete(hookToUintptr, hook)
		delete(hookDataMap, uptr)
	}
	return errReturn(C.uc_hook_del(u.handle, C.uc_hook(hook)))
}
Beispiel #2
0
func (u *uc) HookDel(hook Hook) error {
	if uptr, ok := u.hooks[hook]; ok {
		delete(u.hooks, hook)
		hookDataLock.Lock()
		delete(hookDataMap, uptr)
		hookDataLock.Unlock()
	}
	return errReturn(C.uc_hook_del(u.handle, C.uc_hook(hook)))
}
Beispiel #3
0
func (u *uc) HookDel(hook Hook) error {
	delete(hookRetain, hook)
	return errReturn(C.uc_hook_del(u.handle, C.uc_hook(hook)))
}