diff mbox series

[10/28] lib: Allow modules to use strnchrnul

Message ID 20250407173149.1010216-1-ivecera@redhat.com (mailing list archive)
State Handled Elsewhere
Headers show
Series Add Microchip ZL3073x support | expand

Commit Message

Ivan Vecera April 7, 2025, 5:31 p.m. UTC
Commit 0bee0cece2a6a ("lib/string: add strnchrnul()") added the
mentioned function but did not export it so it cannot be used by
modules.

Reviewed-by: Michal Schmidt <mschmidt@redhat.com>
Signed-off-by: Ivan Vecera <ivecera@redhat.com>
---
 lib/string.c | 1 +
 1 file changed, 1 insertion(+)

Comments

Kees Cook April 7, 2025, 5:50 p.m. UTC | #1
On Mon, Apr 07, 2025 at 07:31:40PM +0200, Ivan Vecera wrote:
> Commit 0bee0cece2a6a ("lib/string: add strnchrnul()") added the
> mentioned function but did not export it so it cannot be used by
> modules.
> 
> Reviewed-by: Michal Schmidt <mschmidt@redhat.com>
> Signed-off-by: Ivan Vecera <ivecera@redhat.com>

Acked-by: Kees Cook <kees@kernel.org>
diff mbox series

Patch

diff --git a/lib/string.c b/lib/string.c
index eb4486ed40d25..824b3aac86de0 100644
--- a/lib/string.c
+++ b/lib/string.c
@@ -363,6 +363,7 @@  char *strnchrnul(const char *s, size_t count, int c)
 		s++;
 	return (char *)s;
 }
+EXPORT_SYMBOL(strnchrnul);
 
 #ifndef __HAVE_ARCH_STRRCHR
 /**