Re: [libvirt] [PATCH] convert missing server entry points into unsupported errors

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



2009/12/22 Daniel Veillard <veillard@xxxxxxxxxx>:
>  If using a remote access, sometimes an RPC entry point is not
> available, and currently we just end up with a raw:
>   error: unknown procedure: xxx
> error, while this should be more cleanly reported as an unsupported
> entry point like for local access, e.g when calling an older RHEL-5.3
>
> without patch
>
> paphio:~/libvirt -> tools/virsh --connect xen+ssh://root@test3 dominfo
> test5
> Id:             1
> Name:           test5
> UUID:           62cd4e2e-5117-e4ba-2dbf-68a37031c3e4
> OS Type:        linux
> State:          idle
> CPU(s):         1
> CPU time:       254.5s
> Max memory:     524288 kB
> Used memory:    524108 kB
> error: unknown procedure: 122
>
> with patch
>
> paphio:~/libvirt -> tools/virsh --connect xen+ssh://root@test3 dominfo
> test5
> Id:             1
> Name:           test5
> UUID:           62cd4e2e-5117-e4ba-2dbf-68a37031c3e4
> OS Type:        linux
> State:          idle
> CPU(s):         1
> CPU time:       254.6s
> Max memory:     524288 kB
> Used memory:    524080 kB
>
> paphio:~/libvirt ->
>
> the application knows that some feature may not be avilable but expects
> the VIR_ERR_NO_SUPPORT to be reported, not an internal RPC problem,
>
> I also noticed that we do
>
>  "%s", thiscall->err.message ? *thiscall->err.message : NULL);
>
> for passing the error message, which is a sure way to crash if there is
> no error message and changing this to
>
>  "%s", thiscall->err.message ? *thiscall->err.message : "unknown");
>
> I expect the server to always return an error message in practice, but
> this need fixing.
>
> Daniel
>

ACK.

Matthias

--
Libvir-list mailing list
Libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list


[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]