Misc QGA fixes for 2025-07-01
The following changes since commit aec6836c73403cffa56b9a4c5556451ee16071fe:
Merge tag 'pull-vfio-20250626' of https://github.com/legoater/qemu into staging (2025-06-26 10:25:01 -0400)
are available in the Git repository at:
https://github.com/kostyanf14/qemu.git tags/qga-pull-2025-07-01
for you to fetch changes up to 1c90e89e64beb2bd72f8e437c56274c885df7b3f:
qga/vss-win32: Add VSS provider unregistration retry (2025-06-30 13:17:10 +0300)
----------------------------------------------------------------
qga-pull-2025-07-01
----------------------------------------------------------------
Elizabeth Ashurov (1):
qga/vss-win32: Add VSS provider unregistration retry
Kostiantyn Kostiuk (2):
MAINTAINERS: Update Kostiantyn Kostiuk transliteration
qga-vss: Exit with non-zero code when register fail
MAINTAINERS | 4 ++-- qga/vss-win32/install.cpp | 15 +++++++++++---- 2 files changed, 13 insertions(+), 6 deletions(-)
--
2.48.1
[PULL 2/3] qga-vss: Exit with non-zero code when register fail
QGA installer uses rundll32 to run the DLLCOMRegister function from qga-vss.dll and perform VSS provider registration. rundll32 ignores the return value of the function and always exits with a zero exit code. This causes a situation where the installer does not know the status of VSS provider registration.
This commit forces to change exit code when the VSS provider registration fails.
https://learn.microsoft.com/en-us/windows-server/administration/windows-commands/rundll32
Message-ID: <[email protected]>
--- qga/vss-win32/install.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-)
qga/vss-win32/install.cpp +4 -1
@@ -385,7 +385,10 @@ out: STDAPI_(void) CALLBACK DLLCOMRegister(HWND, HINSTANCE, LPSTR, int); STDAPI_(void) CALLBACK DLLCOMRegister(HWND, HINSTANCE, LPSTR, int) { - COMRegister(); + HRESULT hr = COMRegister(); + if (FAILED(hr)) { + exit(hr); + } } STDAPI_(void) CALLBACK DLLCOMUnregister(HWND, HINSTANCE, LPSTR, int);
Signature · 1 line
2.48.1
[PULL 3/3] qga/vss-win32: Add VSS provider unregistration retry
In reply to Kostiantyn KostiukFrom: Elizabeth Ashurov <[email protected]>
This commit improves the QGA VSS provider installation flow by attempting to unregister the VSS provider if it's already found during installation. This allows for a retry of installation even if a previous unregistration failed or was not performed. This will prevent inconsistencies between QGA and QGA-VSS versions.
Before this commit, QGA can use QGA-VSS from the previous installation.
Message-ID: <[email protected]>
--- qga/vss-win32/install.cpp | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-)
qga/vss-win32/install.cpp +7 -3
@@ -287,9 +287,13 @@ STDAPI COMRegister(void) chk(QGAProviderFind(QGAProviderCount, (void *)&count)); if (count) { - errmsg(E_ABORT, "QGA VSS Provider is already installed"); - qga_debug_end; - return E_ABORT; + qga_debug("QGA VSS Provider is already installed. Attempting to unregister first."); + hr = COMUnregister(); + if (FAILED(hr)) { + errmsg(hr, "Failed to unregister existing QGA VSS Provider. Aborting installation."); + qga_debug_end; + return E_ABORT; + } } chk(CoCreateInstance(CLSID_COMAdminCatalog, NULL, CLSCTX_INPROC_SERVER,
Signature · 1 line
2.48.1
[PULL 1/3] MAINTAINERS: Update Kostiantyn Kostiuk transliteration
In reply to Kostiantyn KostiukMessage-ID: <[email protected]>
--- MAINTAINERS | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
MAINTAINERS +2 -2
@@ -3383,7 +3383,7 @@ T: git https://repo.or.cz/qemu/armbru.git qapi-next QEMU Guest Agent M: Michael Roth <[email protected]> -M: Konstantin Kostiuk <[email protected]> +M: Kostiantyn Kostiuk <[email protected]> S: Maintained F: qga/ F: contrib/systemd/qemu-guest-agent.service
@@ -3394,7 +3394,7 @@ F: tests/*/test-qga* T: git https://github.com/mdroth/qemu.git qga QEMU Guest Agent Win32 -M: Konstantin Kostiuk <[email protected]> +M: Kostiantyn Kostiuk <[email protected]> S: Maintained F: qga/*win32* F: qga/vss-win32/
Signature · 1 line
2.48.1
Stefan Hajnoczi
AppliedApplied, thanks.
Please update the changelog at https://wiki.qemu.org/ChangeLog/10.1 for any user-visible changes.