summaryrefslogtreecommitdiff
path: root/librpc/ndr/ndr.c
diff options
context:
space:
mode:
authorStefan Metzmacher <metze@samba.org>2010-02-18 13:40:44 +0100
committerStefan Metzmacher <metze@samba.org>2010-02-18 13:44:04 +0100
commit4a76d29374769ba4c075b8d5767498848d2e17d6 (patch)
treed34e470894d8e44c7443b157f58c3e5fb22812d7 /librpc/ndr/ndr.c
parent31c7780c16651b284009874cf3da04587dc36d19 (diff)
downloadsamba-4a76d29374769ba4c075b8d5767498848d2e17d6.tar.gz
samba-4a76d29374769ba4c075b8d5767498848d2e17d6.tar.bz2
samba-4a76d29374769ba4c075b8d5767498848d2e17d6.zip
libndr: for now align reverse relative pointers to 2 bytes by default.
This is just a hack and we should let the callers use FLAG_ALIGN2 explicit in future. metze
Diffstat (limited to 'librpc/ndr/ndr.c')
-rw-r--r--librpc/ndr/ndr.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/librpc/ndr/ndr.c b/librpc/ndr/ndr.c
index 93fbb995f9..61745aa55a 100644
--- a/librpc/ndr/ndr.c
+++ b/librpc/ndr/ndr.c
@@ -1222,6 +1222,9 @@ _PUBLIC_ enum ndr_err_code ndr_push_relative_ptr2_end(struct ndr_push *ndr, cons
/* the reversed offset is at the end of the main buffer */
correct_offset = ndr->relative_end_offset - len;
+ /* TODO: remove this hack and let the idl use FLAG_ALIGN2 explicit */
+ align = 2;
+
if (ndr->flags & LIBNDR_FLAG_ALIGN2) {
align = 2;
} else if (ndr->flags & LIBNDR_FLAG_ALIGN4) {