[PATCH] libxl: constify libxl__stubdomain_is_linux

Jason Andryuk posted 1 patch 2 years, 1 month ago
Test gitlab-ci failed
Patches applied successfully (tree, apply log)
git fetch https://gitlab.com/xen-project/patchew/xen tags/patchew/20220330181722.30280-1-jandryuk@gmail.com
tools/libs/light/libxl_internal.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
[PATCH] libxl: constify libxl__stubdomain_is_linux
Posted by Jason Andryuk 2 years, 1 month ago
libxl__stubdomain_is_linux can take a const pointer, so make the change.

This isn't an issue in-tree, but was found with an OpenXT patch where it
was called with only const libxl_domain_build_info available.

Signed-off-by: Jason Andryuk <jandryuk@gmail.com>
---
 tools/libs/light/libxl_internal.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/tools/libs/light/libxl_internal.h b/tools/libs/light/libxl_internal.h
index c0e7779d97..a26daec040 100644
--- a/tools/libs/light/libxl_internal.h
+++ b/tools/libs/light/libxl_internal.h
@@ -2326,7 +2326,7 @@ bool libxl__stubdomain_is_linux_running(libxl__gc *gc, uint32_t domid)
 }
 
 static inline
-bool libxl__stubdomain_is_linux(libxl_domain_build_info *b_info)
+bool libxl__stubdomain_is_linux(const libxl_domain_build_info *b_info)
 {
     /* right now qemu-tranditional implies MiniOS stubdomain and qemu-xen
      * implies Linux stubdomain */
-- 
2.35.1