[PATCH 3/4] lib: drop fwts_memcpy_unaligned

Leif Lindholm leif.lindholm at linaro.org
Thu Nov 15 23:25:16 UTC 2018


fwts_memcpy_unaligned has no users left in the tree, so drop it.

Signed-off-by: Leif Lindholm <leif.lindholm at linaro.org>
---
 src/lib/include/fwts_stringextras.h |  1 -
 src/lib/src/fwts_stringextras.c     | 15 ---------------
 2 files changed, 16 deletions(-)

diff --git a/src/lib/include/fwts_stringextras.h b/src/lib/include/fwts_stringextras.h
index cd5fa822..7b605b4b 100644
--- a/src/lib/include/fwts_stringextras.h
+++ b/src/lib/include/fwts_stringextras.h
@@ -25,6 +25,5 @@
 void fwts_chop_newline(char *str);
 char *fwts_realloc_strcat(char *orig, const char *newstr);
 const char *fwts_string_endswith(const char *str, const char *postfix);
-void fwts_memcpy_unaligned(void *dst, const void *src, size_t n);
 
 #endif
diff --git a/src/lib/src/fwts_stringextras.c b/src/lib/src/fwts_stringextras.c
index 1f22224d..b4053579 100644
--- a/src/lib/src/fwts_stringextras.c
+++ b/src/lib/src/fwts_stringextras.c
@@ -98,18 +98,3 @@ const char *fwts_string_endswith(const char *str, const char *postfix)
 
 	return str + sl - pl;
 }
-
-/*
- * fwts_memcpy_unaligned()
- *     perform byte copy of n bytes from src to dst.
- */
-void fwts_memcpy_unaligned(void *dst, const void *src, size_t n)
-{
-	size_t i = n;
-
-	if (dst == NULL || src == NULL || n == 0 )
-		return;
-
-	while (i--)
-		((uint8_t *)dst)[i] = ((const uint8_t *)src)[i];
-}
-- 
2.11.0




More information about the fwts-devel mailing list