summaryrefslogtreecommitdiff
path: root/source4/rpc_server/samr
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>2004-11-02 02:57:18 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 13:05:13 -0500
commitedbfc0f6e70150e321822365bf0eead2821551bd (patch)
tree38164393e1f9b5225662453fb6253947e7fdc086 /source4/rpc_server/samr
parent452ddd94ba22bebe0fda5ee6a7ddceae2057fe40 (diff)
downloadsamba-edbfc0f6e70150e321822365bf0eead2821551bd.tar.gz
samba-edbfc0f6e70150e321822365bf0eead2821551bd.tar.bz2
samba-edbfc0f6e70150e321822365bf0eead2821551bd.zip
r3453: - split out the auth and popt includes
- tidied up some of the system includes - moved a few more structures back from misc.idl to netlogon.idl and samr.idl now that pidl knows about inter-IDL dependencies (This used to be commit 7b7477ac42d96faac1b0ff361525d2c63cedfc64)
Diffstat (limited to 'source4/rpc_server/samr')
-rw-r--r--source4/rpc_server/samr/dcesrv_samr.c2
-rw-r--r--source4/rpc_server/samr/samdb.c7
2 files changed, 5 insertions, 4 deletions
diff --git a/source4/rpc_server/samr/dcesrv_samr.c b/source4/rpc_server/samr/dcesrv_samr.c
index b3938ce417..e1dc234f19 100644
--- a/source4/rpc_server/samr/dcesrv_samr.c
+++ b/source4/rpc_server/samr/dcesrv_samr.c
@@ -1054,7 +1054,7 @@ static NTSTATUS samr_OpenGroup(struct dcesrv_call_state *dce_call, TALLOC_CTX *m
} while (0)
#define SET_LHOURS(msg, field, attr) do { \
- if (samdb_msg_add_logon_hours(a_state->sam_ctx, mem_ctx, msg, attr, r->in.info->field) != 0) { \
+ if (samdb_msg_add_logon_hours(a_state->sam_ctx, mem_ctx, msg, attr, &r->in.info->field) != 0) { \
return NT_STATUS_NO_MEMORY; \
} \
} while (0)
diff --git a/source4/rpc_server/samr/samdb.c b/source4/rpc_server/samr/samdb.c
index 3fb8fcef1e..15796a695e 100644
--- a/source4/rpc_server/samr/samdb.c
+++ b/source4/rpc_server/samr/samdb.c
@@ -21,6 +21,7 @@
*/
#include "includes.h"
+#include "librpc/gen_ndr/ndr_netlogon.h"
/*
connect to the SAM database
@@ -789,12 +790,12 @@ int samdb_msg_add_acct_flags(void *ctx, TALLOC_CTX *mem_ctx, struct ldb_message
add a logon_hours element to a message
*/
int samdb_msg_add_logon_hours(void *ctx, TALLOC_CTX *mem_ctx, struct ldb_message *msg,
- const char *attr_name, struct samr_LogonHours hours)
+ const char *attr_name, struct samr_LogonHours *hours)
{
struct ldb_wrap *sam_ctx = ctx;
struct ldb_val val;
- val.length = hours.units_per_week / 8;
- val.data = hours.bitmap;
+ val.length = hours->units_per_week / 8;
+ val.data = hours->bitmap;
ldb_set_alloc(sam_ctx->ldb, talloc_realloc_fn, mem_ctx);
return ldb_msg_add_value(sam_ctx->ldb, msg, attr_name, &val);
}