summaryrefslogtreecommitdiff
path: root/source4/torture/rap
diff options
context:
space:
mode:
authorStefan Metzmacher <metze@samba.org>2004-11-25 19:13:41 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 13:06:09 -0500
commitf9bbcc53d69641ffc54267d506165aafbf1a0b98 (patch)
tree407549647c37c4e00a0291a71a34f534f00219d9 /source4/torture/rap
parent4bc68cba73cfdf8f6aac75d8fcc1bdb22f29acd3 (diff)
downloadsamba-f9bbcc53d69641ffc54267d506165aafbf1a0b98.tar.gz
samba-f9bbcc53d69641ffc54267d506165aafbf1a0b98.tar.bz2
samba-f9bbcc53d69641ffc54267d506165aafbf1a0b98.zip
r3966: fix compiler warnings
metze (This used to be commit 531c4654e0c2e8d150f8337cb84a6746fc1abee9)
Diffstat (limited to 'source4/torture/rap')
-rw-r--r--source4/torture/rap/rap.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/source4/torture/rap/rap.c b/source4/torture/rap/rap.c
index d7cbd9f750..b47cfa2997 100644
--- a/source4/torture/rap/rap.c
+++ b/source4/torture/rap/rap.c
@@ -134,7 +134,7 @@ static NTSTATUS rap_pull_string(TALLOC_CTX *mem_ctx, struct ndr_pull *ndr,
{
uint16 string_offset;
uint16 ignore;
- char *p;
+ const char *p;
size_t len;
NDR_CHECK(ndr_pull_uint16(ndr, &string_offset));
@@ -145,7 +145,7 @@ static NTSTATUS rap_pull_string(TALLOC_CTX *mem_ctx, struct ndr_pull *ndr,
if (string_offset+1 > ndr->data_size)
return NT_STATUS_INVALID_PARAMETER;
- p = ndr->data + string_offset;
+ p = (const char *)(ndr->data + string_offset);
len = strnlen(p, ndr->data_size-string_offset);
if ( string_offset + len + 1 > ndr->data_size )
@@ -260,13 +260,13 @@ static NTSTATUS smbcli_rap_netshareenum(struct smbcli_state *cli,
switch(r->in.level) {
case 0:
NDR_OK(ndr_pull_bytes(call->ndr_pull_data,
- r->out.info[i].info0.name, 13));
+ (uint8_t *)r->out.info[i].info0.name, 13));
break;
case 1:
NDR_OK(ndr_pull_bytes(call->ndr_pull_data,
- r->out.info[i].info1.name, 13));
+ (uint8_t *)r->out.info[i].info1.name, 13));
NDR_OK(ndr_pull_bytes(call->ndr_pull_data,
- &r->out.info[i].info1.pad, 1));
+ (uint8_t *)&r->out.info[i].info1.pad, 1));
NDR_OK(ndr_pull_uint16(call->ndr_pull_data,
&r->out.info[i].info1.type));
NDR_OK(rap_pull_string(mem_ctx, call->ndr_pull_data,
@@ -354,11 +354,11 @@ static NTSTATUS smbcli_rap_netserverenum2(struct smbcli_state *cli,
switch(r->in.level) {
case 0:
NDR_OK(ndr_pull_bytes(call->ndr_pull_data,
- r->out.info[i].info0.name, 16));
+ (uint8_t *)r->out.info[i].info0.name, 16));
break;
case 1:
NDR_OK(ndr_pull_bytes(call->ndr_pull_data,
- r->out.info[i].info1.name, 16));
+ (uint8_t *)r->out.info[i].info1.name, 16));
NDR_OK(ndr_pull_bytes(call->ndr_pull_data,
&r->out.info[i].info1.version_major, 1));
NDR_OK(ndr_pull_bytes(call->ndr_pull_data,