aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDarrick J. Wong <djwong@kernel.org>2023-03-14 18:01:10 -0700
committerCarlos Maiolino <cem@kernel.org>2023-03-17 11:37:41 +0100
commit4f82f9218bb333bccb35ddfd0f89c341fdd58c36 (patch)
tree12b9573bc67573ccd5a0f61d02bca7138d40eeae
parentb7b81f336ac02f4e4f24e0844a7fb3023c489667 (diff)
downloadxfsprogs-dev-4f82f9218bb333bccb35ddfd0f89c341fdd58c36.tar.gz
xfs_db: fix complaints about unsigned char casting
Make the warnings about signed/unsigned char pointer casting go away. For printing dirent names it doesn't matter at all. Signed-off-by: Darrick J. Wong <djwong@kernel.org> Reviewed-by: Carlos Maiolino <cmaiolino@redhat.com> Signed-off-by: Carlos Maiolino <cem@kernel.org>
-rw-r--r--db/namei.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/db/namei.c b/db/namei.c
index 00e8c8dc6d..063721ca98 100644
--- a/db/namei.c
+++ b/db/namei.c
@@ -98,7 +98,7 @@ path_navigate(
for (i = 0; i < dirpath->depth; i++) {
struct xfs_name xname = {
- .name = dirpath->path[i],
+ .name = (unsigned char *)dirpath->path[i],
.len = strlen(dirpath->path[i]),
};
@@ -250,7 +250,7 @@ dir_emit(
uint8_t dtype)
{
char *display_name;
- struct xfs_name xname = { .name = name };
+ struct xfs_name xname = { .name = (unsigned char *)name };
const char *dstr = get_dstr(mp, dtype);
xfs_dahash_t hash;
bool good;