> On 19 Jun 2019, at 11:14, Daniel P. Berrangé <[email protected]> wrote:
>
> On Wed, Jun 19, 2019 at 10:50:14AM +0200, Christophe de Dinechin wrote:
>
> So the first thing our Go code does is check the libvirt native library
> version number and report an error
>
> eg
>
> func (n *NetworkPort) Delete(flags uint) error {
> if C.LIBVIR_VERSION_NUMBER < 5005000 {
> return makeNotImplementedError("virNetworkPortDelete")
> }
Duh, of course, that’s supposed to be the only consumer!
I somehow imagined that the wrappers themselves were exposed,
i.e. some Go programmer could have some weird reason to write
C.virtFunc(blah)
I don’t think you can prevent it, but I agree that with proper Go wrappers,
there
is no reason this would ever happen…
FWIW, the code looks sane to me, but I don’t consider myself enough of an
expert in this area to report a Reviewed-by.
--
libvir-list mailing list
[email protected]
https://www.redhat.com/mailman/listinfo/libvir-list