[libvirt] [PATCH] Fix double-free and broken logic in virt-login-shell

Daniel P. Berrange berrange at redhat.com
Fri Aug 9 12:29:07 UTC 2013


On Fri, Aug 09, 2013 at 06:27:36AM -0600, Eric Blake wrote:
> On 08/09/2013 05:01 AM, Daniel P. Berrange wrote:
> > From: "Daniel P. Berrange" <berrange at redhat.com>
> > 
> > The virLoginShellAllowedUser method must not free the 'groups'
> > parameter it is given, as that is owned by the caller.
> > 
> > The virLoginShellAllowedUser method should be checking
> > '!*ptr' (ie empty string) rather than '!ptr' (NULL string)
> > since the latter cannot be true.
> 
> This only fixes the blatant errors that I called out, but there are
> still more (cosmetic) fixes needed:
> https://www.redhat.com/archives/libvir-list/2013-August/msg00398.html

Ah, I didn't see your reply - i was just responding to John's
coverity report. I'll put together a patch for the other fixes
too.


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