On 04/28/2017 03:46 AM, Erik Skultety wrote: > virMediatedDeviceListAdd calls VIR_APPEND_ELEMENT which normally clears > the element to be added, thus the pointer must not be used afterwards, > but because the pointer here is passed by value, what gets cleared is > a copy of the original pointer that got created on the stack > automatically when calling the function. The fact that it works now is > just a coincidence and a bug in virMediatedDeviceListAdd that needs to > be fixed in a separate commit. Therefore, use a local variable to hold > data, rather than accessing the pointer later. > > Signed-off-by: Erik Skultety <eskultet@xxxxxxxxxx> Reviewed-by: Laine Stump <laine@xxxxxxxxx> (Oh, and "safe for freeze", in case that wasn't assumed. Same goes for 2/2) -- libvir-list mailing list libvir-list@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/libvir-list