[libvirt] [PATCH 00/15] fix misuse of 'const fooPtr'

Daniel P. Berrange berrange at redhat.com
Wed Oct 9 09:27:23 UTC 2013


On Tue, Oct 08, 2013 at 11:24:57AM -0600, Eric Blake wrote:
> Mostly cleanup, but at least one bug fix (xen was instantiating
> a memballoon device too early, during the post-parse callback
> of the first device rather than after all devices were known).
> 
> Spawned by the conversation here:
> https://www.redhat.com/archives/libvir-list/2013-September/thread.html#01311

If we're going down the route of removing 'Ptr' suffixes in favour
of normal '*' where we need to have const, how about just doing
away with this 'Ptr' suffix *everywhere* (well except public header
where we'd need to keep the typedef for back compat). Internally
we could completely remove it though.  The 'Ptr' typedefs actually
may the code longer, for no obvious benefit, and create problems
with const-ness.

The main problem is that the huge change would create pain for people
backporting patches.

Daniel
-- 
|: http://berrange.com      -o-    http://www.flickr.com/photos/dberrange/ :|
|: http://libvirt.org              -o-             http://virt-manager.org :|
|: http://autobuild.org       -o-         http://search.cpan.org/~danberr/ :|
|: http://entangle-photo.org       -o-       http://live.gnome.org/gtk-vnc :|




More information about the libvir-list mailing list