Browse Source

tests: fix -Wwrite-strings

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
main
Marc-André Lureau 2 years ago committed by David Gibson
parent
commit
44c9b73801
  1. 4
      tests/path_offset.c
  2. 2
      tests/utilfdt_test.c

4
tests/path_offset.c

@ -41,7 +41,7 @@ static int check_subnode(void *fdt, int parent, const char *name) @@ -41,7 +41,7 @@ static int check_subnode(void *fdt, int parent, const char *name)
return offset;
}

static void check_path_offset(void *fdt, char *path, int offset)
static void check_path_offset(void *fdt, const char *path, int offset)
{
int rc;

@ -56,7 +56,7 @@ static void check_path_offset(void *fdt, char *path, int offset) @@ -56,7 +56,7 @@ static void check_path_offset(void *fdt, char *path, int offset)
" %d instead of %d", path, rc, offset);
}

static void check_path_offset_namelen(void *fdt, char *path, int namelen,
static void check_path_offset_namelen(void *fdt, const char *path, int namelen,
int offset)
{
int rc;

2
tests/utilfdt_test.c

@ -50,7 +50,7 @@ static void checkfail(const char *fmt) @@ -50,7 +50,7 @@ static void checkfail(const char *fmt)
* \param expected_size The size (in bytes) that we expect (ignored for
* strings)
*/
static void check_sizes(char *modifier, int expected_size)
static void check_sizes(const char *modifier, int expected_size)
{
char fmt[10], *ptr;


Loading…
Cancel
Save