qemu-ga patch queue for 2.6
* fix w32 bug where output from guest-exec is not properly captured * fix w32 bug where FDs are leaked after guest-exec is invoked -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 iQEcBAABAgAGBQJXBo7dAAoJEDNTyc7xCLWEGi0H/RP25JGWl4gCy54jlPRbvIl6 Q/aX3QdPJdBcGtLl4WbqTu9BuOuCWc2f7XcCkeApqQcEeey8xb34sos8uE/ItfnH FOLSwkFLjavOVotvtATS9XMGqYAzzeaMyVYaIqAS5jzBF6WyvUD80dNwXtkuh9cb A9L66wzuXy8r5SVaktdgkqvDmvrLRyy3E07tYA1m4x4OUYQUGU8W86G+UYbjKUmP gEJP5mTwEUxyQ2LpnP2k1qRbTE2im3+DfYjc67dn56WL3jf9/sZ0/JhacD4EzR+0 Qje2PbUCMCQANgxV/eDcONm03pAxz149CcEoVTbEvjNe1Rob8dtefOvwAj0QmQA= =pHUI -----END PGP SIGNATURE----- Merge remote-tracking branch 'remotes/mdroth/tags/qga-pull-2016-04-07-tag' into staging qemu-ga patch queue for 2.6 * fix w32 bug where output from guest-exec is not properly captured * fix w32 bug where FDs are leaked after guest-exec is invoked # gpg: Signature made Thu 07 Apr 2016 17:46:21 BST using RSA key ID F108B584 # gpg: Good signature from "Michael Roth <flukshun@gmail.com>" # gpg: aka "Michael Roth <mdroth@utexas.edu>" # gpg: aka "Michael Roth <mdroth@linux.vnet.ibm.com>" * remotes/mdroth/tags/qga-pull-2016-04-07-tag: qga: Workaround for console redirection from non-interactive qemu-ga service qga: fix fd leak with guest-exec i/o channels Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
This commit is contained in:
commit
ead5268f21
@ -373,6 +373,7 @@ static gboolean guest_exec_output_watch(GIOChannel *ch,
|
||||
return true;
|
||||
|
||||
close:
|
||||
g_io_channel_shutdown(ch, true, NULL);
|
||||
g_io_channel_unref(ch);
|
||||
g_atomic_int_set(&p->closed, 1);
|
||||
return false;
|
||||
@ -447,6 +448,7 @@ GuestExec *qmp_guest_exec(const char *path,
|
||||
g_io_channel_set_encoding(in_ch, NULL, NULL);
|
||||
g_io_channel_set_buffered(in_ch, false);
|
||||
g_io_channel_set_flags(in_ch, G_IO_FLAG_NONBLOCK, NULL);
|
||||
g_io_channel_set_close_on_unref(in_ch, true);
|
||||
g_io_add_watch(in_ch, G_IO_OUT, guest_exec_input_watch, &gei->in);
|
||||
}
|
||||
|
||||
@ -462,6 +464,8 @@ GuestExec *qmp_guest_exec(const char *path,
|
||||
g_io_channel_set_encoding(err_ch, NULL, NULL);
|
||||
g_io_channel_set_buffered(out_ch, false);
|
||||
g_io_channel_set_buffered(err_ch, false);
|
||||
g_io_channel_set_close_on_unref(out_ch, true);
|
||||
g_io_channel_set_close_on_unref(err_ch, true);
|
||||
g_io_add_watch(out_ch, G_IO_IN | G_IO_HUP,
|
||||
guest_exec_output_watch, &gei->out);
|
||||
g_io_add_watch(err_ch, G_IO_IN | G_IO_HUP,
|
||||
|
@ -96,7 +96,7 @@
|
||||
<File Id="gspawn-win32-helper-console.exe" Name="gspawn-win32-helper-console.exe" Source="$(var.Mingw_bin)/gspawn-win32-helper-console.exe" KeyPath="yes" DiskId="1"/>
|
||||
</Component>
|
||||
<Component Id="gspawn-helper" Guid="{CD67A5A3-2DB1-4DA1-A67A-8D71E797B466}">
|
||||
<File Id="gspawn-win32-helper.exe" Name="gspawn-win32-helper.exe" Source="$(var.Mingw_bin)/gspawn-win32-helper.exe" KeyPath="yes" DiskId="1"/>
|
||||
<File Id="gspawn-win32-helper.exe" Name="gspawn-win32-helper.exe" Source="$(var.Mingw_bin)/gspawn-win32-helper-console.exe" KeyPath="yes" DiskId="1"/>
|
||||
</Component>
|
||||
<?endif?>
|
||||
<?if $(var.Arch) = "64"?>
|
||||
@ -104,7 +104,7 @@
|
||||
<File Id="gspawn-win64-helper-console.exe" Name="gspawn-win64-helper-console.exe" Source="$(var.Mingw_bin)/gspawn-win64-helper-console.exe" KeyPath="yes" DiskId="1"/>
|
||||
</Component>
|
||||
<Component Id="gspawn-helper" Guid="{D201AD22-1846-4E4F-B6E1-C7A908ED2457}">
|
||||
<File Id="gspawn-win64-helper.exe" Name="gspawn-win64-helper.exe" Source="$(var.Mingw_bin)/gspawn-win64-helper.exe" KeyPath="yes" DiskId="1"/>
|
||||
<File Id="gspawn-win64-helper.exe" Name="gspawn-win64-helper.exe" Source="$(var.Mingw_bin)/gspawn-win64-helper-console.exe" KeyPath="yes" DiskId="1"/>
|
||||
</Component>
|
||||
<?endif?>
|
||||
<Component Id="iconv" Guid="{35EE3558-D34B-4F0A-B8BD-430FF0775246}">
|
||||
|
Loading…
Reference in New Issue
Block a user