summaryrefslogtreecommitdiff
path: root/source4
diff options
context:
space:
mode:
authorTim Potter <tpot@samba.org>2005-08-05 15:53:04 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 13:31:18 -0500
commitb056c7ac3460db7c893527b55305d17417ae5e63 (patch)
treeb9a63fbc4cd24daea36d01988f85fd52a9a59f26 /source4
parent71f8de6bb3306f2d6b63f3b1c1551af473caa483 (diff)
downloadsamba-b056c7ac3460db7c893527b55305d17417ae5e63.tar.gz
samba-b056c7ac3460db7c893527b55305d17417ae5e63.tar.bz2
samba-b056c7ac3460db7c893527b55305d17417ae5e63.zip
r9123: Add ejs_pull_DATA_BLOB() and ejs_pull_BOOL() although leave DATA_BLOB
unimplemented for the moment. (This used to be commit 0e022f8d45a99f0edbbd6369dbf41f73906c6fc4)
Diffstat (limited to 'source4')
-rw-r--r--source4/scripting/ejs/ejsrpc.c26
-rw-r--r--source4/scripting/ejs/ejsrpc.h9
2 files changed, 34 insertions, 1 deletions
diff --git a/source4/scripting/ejs/ejsrpc.c b/source4/scripting/ejs/ejsrpc.c
index 5e81e21e4f..f3abc3c34a 100644
--- a/source4/scripting/ejs/ejsrpc.c
+++ b/source4/scripting/ejs/ejsrpc.c
@@ -292,3 +292,29 @@ NTSTATUS ejs_push_lsa_String(struct ejs_rpc *ejs,
return ejs_push_string(ejs, v, name, r->string);
}
+NTSTATUS ejs_pull_DATA_BLOB(struct ejs_rpc *ejs,
+ struct MprVar *v, const char *name, DATA_BLOB *r)
+{
+ return NT_STATUS_NOT_IMPLEMENTED;
+}
+
+NTSTATUS ejs_push_DATA_BLOB(struct ejs_rpc *ejs,
+ struct MprVar *v, const char *name,
+ const DATA_BLOB *r)
+{
+ return NT_STATUS_NOT_IMPLEMENTED;
+}
+
+NTSTATUS ejs_pull_BOOL(struct ejs_rpc *ejs,
+ struct MprVar *v, const char *name, BOOL *r)
+{
+ NDR_CHECK(mprGetVar(&v, name));
+ *r = mprVarToBool(v);
+ return NT_STATUS_OK;
+}
+
+NTSTATUS ejs_push_BOOL(struct ejs_rpc *ejs,
+ struct MprVar *v, const char *name, const BOOL *r)
+{
+ return mprSetVar(v, name, mprCreateBoolVar(*r));
+}
diff --git a/source4/scripting/ejs/ejsrpc.h b/source4/scripting/ejs/ejsrpc.h
index dbd147fe1d..8bd735c739 100644
--- a/source4/scripting/ejs/ejsrpc.h
+++ b/source4/scripting/ejs/ejsrpc.h
@@ -95,7 +95,14 @@ NTSTATUS ejs_push_dom_sid(struct ejs_rpc *ejs,
struct MprVar *v, const char *name, const struct dom_sid *r);
NTSTATUS ejs_push_null(struct ejs_rpc *ejs, struct MprVar *v, const char *name);
BOOL ejs_pull_null(struct ejs_rpc *ejs, struct MprVar *v, const char *name);
-
+NTSTATUS ejs_pull_DATA_BLOB(struct ejs_rpc *ejs,
+ struct MprVar *v, const char *name, DATA_BLOB *r);
+NTSTATUS ejs_push_DATA_BLOB(struct ejs_rpc *ejs,
+ struct MprVar *v, const char *name, const DATA_BLOB *r);
+NTSTATUS ejs_pull_BOOL(struct ejs_rpc *ejs,
+ struct MprVar *v, const char *name, BOOL *r);
+NTSTATUS ejs_push_BOOL(struct ejs_rpc *ejs,
+ struct MprVar *v, const char *name, const BOOL *r);
#define EJS_ALLOC_SIZE(ejs, s, size) do { \
(s) = talloc_size(ejs, size); \