diff --git a/Initialise-bar-fp-as-NULL.patch b/Initialise-bar-fp-as-NULL.patch new file mode 100644 index 0000000..a1470cb --- /dev/null +++ b/Initialise-bar-fp-as-NULL.patch @@ -0,0 +1,20 @@ +Subject: Initialise bar->fp as NULL +From: Ben Brown ben.brown@softiron.com Thu Mar 28 12:35:28 2024 +0000 +Date: Thu Mar 28 12:53:52 2024 +0000: +Git: 0330ebe40cb645df311bab25888c5ca6cc179efe + +Reviewed-by: Richard W.M. Jones +Fixes: https://bugzilla.redhat.com/show_bug.cgi?id=2272045 + +diff --git a/common/progress/progress.c b/common/progress/progress.c +index e4b3066..5848abd 100644 +--- a/common/progress/progress.c ++++ b/common/progress/progress.c +@@ -123,6 +123,7 @@ progress_bar_init (unsigned flags) + bar->machine_readable = 1; + bar->utf8_mode = 0; + bar->have_terminfo = 0; ++ bar->fp = NULL; + } else { + bar->machine_readable = 0; + diff --git a/Split-chown-parameter-on-character.patch b/Split-chown-parameter-on-character.patch new file mode 100644 index 0000000..fb94131 --- /dev/null +++ b/Split-chown-parameter-on-character.patch @@ -0,0 +1,24 @@ +Subject: generator/customize.ml: Split --chown parameter on ':' character +From: Richard W.M. Jones rjones@redhat.com Fri Jan 19 13:18:00 2024 +0000 +Date: Fri Jan 19 13:24:37 2024 +0000: +Git: e9a728bb22dfa1de5328fbbe7d6d7acad2dbed64 + +The previous code split it on ',' which was completely wrong. +(It reveals the lack of testing however). + +Fixes: commit c08032ebe2763f5e9ce5b14e003721475219d390 +Reported-by: Yongkui Guo + +diff --git a/generator/customize.ml b/generator/customize.ml +index e64b45c0d..e2c4b6051 100644 +--- a/generator/customize.ml ++++ b/generator/customize.ml +@@ -775,7 +775,7 @@ let rec argspec () = + let len = String.length arg in + String.sub arg 0 i, String.sub arg (i+1) (len-(i+1)) + and split_string_triplet option_name arg = +- match String.nsplit ~max:3 \",\" arg with ++ match String.nsplit ~max:3 \":\" arg with + | [a; b; c] -> a, b, c + | _ -> + error (f_\"invalid format for '--%%s' parameter, see the man page\") diff --git a/libguestfs.changes b/libguestfs.changes index 69d71d3..96900c9 100644 --- a/libguestfs.changes +++ b/libguestfs.changes @@ -1,3 +1,10 @@ +------------------------------------------------------------------- +Fri Mar 29 13:13:41 MDT 2024 - carnold@suse.com + +- Upstream bug fixes + Split-chown-parameter-on-character.patch + Initialise-bar-fp-as-NULL.patch + ------------------------------------------------------------------- Mon Feb 5 14:24:08 MST 2024 - carnold@suse.com diff --git a/libguestfs.spec b/libguestfs.spec index 098d29c..d3aa2a0 100644 --- a/libguestfs.spec +++ b/libguestfs.spec @@ -33,6 +33,8 @@ Source101: README # Patches Patch1: use-rtc-driftfix-slew-for-x86-only.patch +Patch2: Split-chown-parameter-on-character.patch +Patch3: Initialise-bar-fp-as-NULL.patch BuildRequires: bison BuildRequires: file-devel