On 2015-02-03 at 03:37, Paolo Bonzini wrote:

On 02/02/2015 22:40, Max Reitz wrote:
Before this patch, the "opaque" pointer in an NBD BDS points to a
BDRVNBDState, which contains an NbdClientSession object, which in turn
contains a pointer to the BDS. This pointer may become invalid due to
bdrv_swap(), so drop it, and instead pass the BDS directly to the
nbd-client.c functions which then retrieve the NbdClientSession object
from there.
Looks good, but please change function names from nbd_client_session_foo
to nbd_client_foo or even just nbd_foo if they do not take an
NbdClientSession* as the first parameter.

Ah, that makes a lot of sense, especially concerning the callback functions (albeit they were named nbd_foo already, but well...) which only take a void pointer.

Will do, thanks,

Max

Thanks,

Paolo


Reply via email to