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

Re: [libvirt] [PATCH] vmware: os x support is broken



On 01/03/2014 10:57 AM, Denis Kondratenko wrote:
> Incorrect usage of virAsprintf and vmware-vmx reports to stderr.
> 
> --- https://bugzilla.redhat.com/show_bug.cgi?id=1036248

Oh my - the triple --- leadin confused 'git am':

Applying: vmware: os x support is broken
fatal: patch fragment without header at line 42: @@ -271,17 +271,17 @@
vmwareExtractVersion(struct vmware_driver
*driver)</div><div> </div><div>     switch (driver-&gt;type)
{</div><div>         case VMWARE_DRIVER_PLAYER:</div><div>-          
 if (virAsprintf(&amp;bin, &quot;%s/%s&quot;, vmwarePath,
&quot;vmplayer&quot;))</div>
Repository lacks necessary blobs to fall back on 3-way merge.
Cannot fall back to three-way merge.
Patch failed at 0001 vmware: os x support is broken

so I had to apply it by hand.


>          case VMWARE_DRIVER_PLAYER:
> -            if (virAsprintf(&bin, "%s/%s", vmwarePath, "vmplayer"))
> +            if (virAsprintf(&bin, "%s/%s", vmwarePath, "vmplayer") < 0)

Definitely correct!


>      cmd = virCommandNewArgList(bin, "-v", NULL);
>      virCommandSetOutputBuffer(cmd, &outbuf);
> +
> +    // OS X 10.9.1 and some earlier ver: vmware-vmx reports ver to stderr

We prefer to avoid C99 comments, and the code is self-explanatory enough
that it was easier to just drop the comment (and put it in the commit
message instead).

ACK and pushed.  Congrats on your first libvirt patch!

-- 
Eric Blake   eblake redhat com    +1-919-301-3266
Libvirt virtualization library http://libvirt.org

Attachment: signature.asc
Description: OpenPGP digital signature


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