summaryrefslogtreecommitdiff
path: root/source4/build
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>2003-11-19 07:29:55 +0000
committerAndrew Tridgell <tridge@samba.org>2003-11-19 07:29:55 +0000
commitd60fe829703e1a88858784425d8b670b2b007e5c (patch)
tree99d3da5e3e59215219f5e725feec1b0ffa816ad7 /source4/build
parent897b9d887216b1112a105d0a989a259a0eabc2f1 (diff)
downloadsamba-d60fe829703e1a88858784425d8b670b2b007e5c.tar.gz
samba-d60fe829703e1a88858784425d8b670b2b007e5c.tar.bz2
samba-d60fe829703e1a88858784425d8b670b2b007e5c.zip
slightly more accurate structure alignment code - I need to do proper
recursive alignment soon (This used to be commit d3838c3668d5acb4aee86e3dd5b8d7d23bc842ff)
Diffstat (limited to 'source4/build')
-rw-r--r--source4/build/pidl/parser.pm3
-rw-r--r--source4/build/pidl/util.pm2
2 files changed, 2 insertions, 3 deletions
diff --git a/source4/build/pidl/parser.pm b/source4/build/pidl/parser.pm
index 5a39903b8f..e227d0d374 100644
--- a/source4/build/pidl/parser.pm
+++ b/source4/build/pidl/parser.pm
@@ -80,8 +80,7 @@ sub fn_prefix($)
sub struct_alignment($)
{
my $s = shift;
- # why do we need a minimum alignment of 4 ??
- my $align = 4;
+ my $align = 1;
for my $e (@{$s->{ELEMENTS}}) {
if ($align < util::type_align($e)) {
$align = util::type_align($e);
diff --git a/source4/build/pidl/util.pm b/source4/build/pidl/util.pm
index 67f97e647e..244a78af09 100644
--- a/source4/build/pidl/util.pm
+++ b/source4/build/pidl/util.pm
@@ -214,7 +214,7 @@ sub type_align($)
return 2, if ($type eq "wchar_t");
return 4, if ($type eq "DATA_BLOB");
- return 0;
+ return 4;
}
# this is used to determine if the ndr push/pull functions will need