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

Re: [libvirt] [PATCH] qemud: don't dereference NULL on failed virGetUserDirectory



On Fri, Jan 23, 2009 at 02:23:14PM +0100, Jim Meyering wrote:
> Jim Meyering <jim meyering net> wrote:
> > I spotted this while merging my unix_sock_dir changes:
> ...
> >          char *userdir = virGetUserDirectory(NULL, uid);
> > +        if (userdir == NULL) {
> > +            /* give no diagnostic here; virGetUserDirectory reports OOM  */
> 
> It can also fail due to getpwuid_r failure.
> Here's the patch with corrected comment/log:

Updated patch looks OK.

Rich.

-- 
Richard Jones, Emerging Technologies, Red Hat  http://et.redhat.com/~rjones
Read my OCaml programming blog: http://camltastic.blogspot.com/
Fedora now supports 68 OCaml packages (the OPEN alternative to F#)
http://cocan.org/getting_started_with_ocaml_on_red_hat_and_fedora


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