On 29 Apr 2013, at 12:28, Wouter Verhelst wrote: > In my view, the select loop would: > - Read a request header into a struct nbd_request, and parse it (i.e., > call ntoh* on the right variables of the struct that we read the header > into) > - Figure out if the request is followed by data; if so, read that data > from the socket
>From past experience writing a server, you might want to ask the driver for buffer(s) to put this in rather than allocate them yourself. For instance, a driver with an O_DIRECT backend would want to page align the buffers. -- Alex Bligh ------------------------------------------------------------------------------ Try New Relic Now & We'll Send You this Cool Shirt New Relic is the only SaaS-based application performance monitoring service that delivers powerful full stack analytics. Optimize and monitor your browser, app, & servers with just a few lines of code. Try New Relic and get this awesome Nerd Life shirt! http://p.sf.net/sfu/newrelic_d2d_apr _______________________________________________ Nbd-general mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/nbd-general
