WERROR srvsvc_NetShareCheck(
[in,unique] [string,charset(UTF16)] uint16 *server_unc,
[in] [string,charset(UTF16)] uint16 device_name[],
- [out] srvsvc_ShareType type
+ [out,ref] srvsvc_ShareType *type
);
/**************************/
const char **names;
int count, i;
- ZERO_STRUCT(r->out);
+ *r->out.type = 0;
/* TODO: - access check
*/
if (strcmp("", r->in.device_name) == 0) {
- r->out.type = STYPE_IPC;
+ *r->out.type = STYPE_IPC;
return WERR_OK;
}
if (!type) continue;
if (strcmp(type, "DISK") == 0) {
- r->out.type = STYPE_DISKTREE;
+ *r->out.type = STYPE_DISKTREE;
return WERR_OK;
}
if (strcmp(type, "IPC") == 0) {
- r->out.type = STYPE_IPC;
+ *r->out.type = STYPE_IPC;
return WERR_OK;
}
if (strcmp(type, "PRINTER") == 0) {
- r->out.type = STYPE_PRINTQ;
+ *r->out.type = STYPE_PRINTQ;
return WERR_OK;
}
}
{
NTSTATUS status;
struct srvsvc_NetShareCheck r;
+ enum srvsvc_ShareType type;
r.in.server_unc = talloc_asprintf(tctx, "\\\\%s", dcerpc_server_name(p));
r.in.device_name = device_name;
+ r.out.type = &type;
torture_comment(tctx,
"testing NetShareCheck on device '%s'\n", r.in.device_name);