[PATCH] tevent: add another example

Ralph Böhme rb at sernet.de
Thu Jul 17 14:20:15 MDT 2014


On Thu, Jul 17, 2014 at 09:40:04PM +0200, Volker Lendecke wrote:
> On Thu, Jul 17, 2014 at 07:32:57PM +0200, Ralph Böhme wrote:
> > while trying to become familiar with tevent I wrote a simple example
> > implementing n * m multiplication in terms of n add m subrequests.
> > 
> > As a first step I moved the existing example to a subdirectory
> > 'examples' (lib/tevent/examples), hope that makes sense.
> 
> Let me take a look why it works. My pattern would have been
> a tevent_req_done() in add_send() before the
> tevent_req_post. That being not there is at least unexpected
> to me.

from <https://tevent.samba.org/group__tevent__request.html#ga680dd2f03889aa7047143bbe52d6e938>

"Finish a request before the caller had the change to set the
callback. An implementation of an async request might find that it can
either finish the request without waiting for an external event, or
..."

-Ralph

-- 
SerNet GmbH, Bahnhofsallee 1b, 37081 Göttingen
phone: +49-551-370000-0, fax: +49-551-370000-9
AG Göttingen, HRB 2816, GF: Dr. Johannes Loxen
http://www.sernet.de,mailto:kontakt@sernet.de


More information about the samba-technical mailing list