summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--source4/ntvfs/ipc/rap_server.c2
-rw-r--r--source4/torture/rap/rap.c4
-rw-r--r--source4/torture/rap/rpc.c4
3 files changed, 5 insertions, 5 deletions
diff --git a/source4/ntvfs/ipc/rap_server.c b/source4/ntvfs/ipc/rap_server.c
index 825a17fd12..b919cbcb20 100644
--- a/source4/ntvfs/ipc/rap_server.c
+++ b/source4/ntvfs/ipc/rap_server.c
@@ -65,7 +65,7 @@ NTSTATUS rap_netshareenum(TALLOC_CTX *mem_ctx,
DEBUG(3, ("WARNING: Service [%s] disappeared after enumeration!\n", snames[i]));
continue;
}
- strncpy(r->out.info[j].info1.share_name,
+ strncpy((char *)r->out.info[j].info1.share_name,
snames[i],
sizeof(r->out.info[0].info1.share_name));
r->out.info[i].info1.reserved1 = 0;
diff --git a/source4/torture/rap/rap.c b/source4/torture/rap/rap.c
index 158bf77e1b..57d27ed32f 100644
--- a/source4/torture/rap/rap.c
+++ b/source4/torture/rap/rap.c
@@ -161,7 +161,7 @@ static void rap_cli_expect_format(struct rap_call *call, const char *format)
}
static NTSTATUS rap_pull_string(TALLOC_CTX *mem_ctx, struct ndr_pull *ndr,
- uint16_t convert, char **dest)
+ uint16_t convert, const char **dest)
{
uint16_t string_offset;
uint16_t ignore;
@@ -183,7 +183,7 @@ static NTSTATUS rap_pull_string(TALLOC_CTX *mem_ctx, struct ndr_pull *ndr,
return NT_STATUS_INVALID_PARAMETER;
*dest = talloc_zero_array(mem_ctx, char, len+1);
- pull_string(*dest, p, len+1, len, STR_ASCII);
+ pull_string((char *)*dest, p, len+1, len, STR_ASCII);
return NT_STATUS_OK;
}
diff --git a/source4/torture/rap/rpc.c b/source4/torture/rap/rpc.c
index f245a919ef..7696ed8e41 100644
--- a/source4/torture/rap/rpc.c
+++ b/source4/torture/rap/rpc.c
@@ -65,7 +65,7 @@ static bool test_rpc_netservergetinfo(struct torture_context *tctx,
server_name = talloc_strndup(tctx, info.info101->server_name, 16);
- torture_assert_str_equal(tctx, r.out.info.info0.name, server_name, "server name");
+ torture_assert_str_equal(tctx, (const char *)r.out.info.info0.name, server_name, "server name");
if (torture_setting_bool(tctx, "samba3", false)) {
torture_skip(tctx, "skipping netservergetinfo level 1 against samba3");
@@ -79,7 +79,7 @@ static bool test_rpc_netservergetinfo(struct torture_context *tctx,
torture_assert_int_equal(tctx, r.out.status, 0,
"rap_netservergetinfo level 1 failed");
- torture_assert_str_equal(tctx, r.out.info.info1.name, server_name, "server name");
+ torture_assert_str_equal(tctx, (const char *)r.out.info.info1.name, server_name, "server name");
torture_assert_int_equal(tctx, r.out.info.info1.version_major, info.info101->version_major, "version major");
torture_assert_int_equal(tctx, r.out.info.info1.version_minor, info.info101->version_minor, "version minor");
torture_assert_int_equal(tctx, r.out.info.info1.servertype, info.info101->server_type, "server_type");