Skip to contentSkip to conversation

lib-glob-initialize-back_str-to-silence-uninitialized-variable-warning.patch removed from -mm tree

merged mm-nonmm-stable Andrew Morton 1 participant 1 message Mar 28

lore
Share & tools
lore

Andrew Morton

author tree notice Applied
#0 lore raw

The quilt patch titled
Subject: lib/glob: initialize back_str to silence uninitialized variable warning
has been removed from the -mm tree. Its filename was
lib-glob-initialize-back_str-to-silence-uninitialized-variable-warning.patch

This patch was dropped because it was merged into the mm-nonmm-stable branch of git://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm

------------------------------------------------------
From: Josh Law <[email protected]>
Subject: lib/glob: initialize back_str to silence uninitialized variable warning
Date: Thu, 12 Mar 2026 21:52:49 +0000

back_str is only used when back_pat is non-NULL, and both are always set together, so it is safe in practice. Initialize back_str to NULL to make this safety invariant explicit and silence compiler/static analysis warnings.

---

 lib/glob.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
lib/glob.c renamed from lib/glob.c~lib-glob-initialize-back_str-to-silence-uninitialized-variable-warning +1 -1
@@ -47,7 +47,7 @@ bool __pure glob_match(char const *pat,
 	 * (no exception for /), it can be easily proved that there's
 	 * never a need to backtrack multiple levels.
 	 */
-	char const *back_pat = NULL, *back_str;
+	char const *back_pat = NULL, *back_str = NULL;
 
 	/*
 	 * Loop over each token (character or class) in pat, matching

_

Patches currently in -mm which might be from [email protected] are

mm-damon-core-document-damos_commit_dests-failure-semantics.patch lib-maple_tree-fix-swapped-arguments-in-mas_safe_pivot-call.patch lib-idr-fix-ida_find_first_range-missing-ids-across-chunk-boundaries.patch