[PATCH] Patchset for bug #10344 - SessionLogoff on a signed connection with an outstanding notify request crashes smbd.

Stefan (metze) Metzmacher metze at samba.org
Wed Mar 5 07:05:09 MST 2014


Hi Jeremy,

>> I really hate this patches, but I don't have something better currently :-)
> 
> Why thank you :-).

The re-entrant thing totally destroys the simplicity of tevent_req based
programming, where you always now who the caller is. But this
jumps from deep down the stack recursively back into the caller
and re-schedules itself. The fact that this is a implicit deferred
recursion makes it even worse.

This is currently needed in order to call become_user(),
but it's very very hard to understand. The complexity isn't better
than nested event loops...

Once I've finished my
https://git.samba.org/?p=metze/samba/wip.git;a=shortlog;h=refs/heads/master3-impersonate
branch, we'll have wrapper tevent contexts, which will take care of
become_user(),
for the event handler.

Then we can get rid of the re-entrant hell again.

metze


More information about the samba-technical mailing list