Login
Username:

Password:

Remember me



Lost Password?

Register now!

Sections

Who's Online
103 user(s) are online (91 user(s) are browsing Forums)

Members: 0
Guests: 103

more...

Support us!

Headlines

Report message:*
 

Is Forbid() needed for SetMethod()?

Subject: Is Forbid() needed for SetMethod()?
by Capehill on 2019/4/8 18:43:17

Simple question for you gurus :)

When wrapping an existing interface function, do I need to use Forbid/Permit pair:

void newFunc() {
  
log(...);
  
oldFunc(...);
}

Forbid();
oldFunc SetMethod(newFunc);
Permit();


If so, why? I mean, if SetMethod requires Forbid(), why it doesn't handle it internally then?

EDIT: updated scenario a bit.

Powered by XOOPS 2.0 © 2001-2016 The XOOPS Project