summaryrefslogtreecommitdiff
path: root/librpc
diff options
context:
space:
mode:
Diffstat (limited to 'librpc')
-rw-r--r--librpc/ndr/ndr.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/librpc/ndr/ndr.c b/librpc/ndr/ndr.c
index 4e584e102b..0ff43c3eb4 100644
--- a/librpc/ndr/ndr.c
+++ b/librpc/ndr/ndr.c
@@ -1160,7 +1160,12 @@ _PUBLIC_ enum ndr_err_code ndr_push_relative_ptr2_start(struct ndr_push *ndr, co
if (p == NULL) {
return NDR_ERR_SUCCESS;
}
- return ndr_push_relative_ptr2(ndr, p);
+ if (!(ndr->flags & LIBNDR_FLAG_RELATIVE_REVERSE)) {
+ return ndr_push_relative_ptr2(ndr, p);
+ }
+
+ return ndr_push_error(ndr, NDR_ERR_RELATIVE,
+ "ndr_push_relative_ptr2_start RELATIVE_REVERSE flag set, but not supported");
}
/*