pidl: For wireshark check also LIBNDR_FLAG_NOALIGN for not aligning
authorMatthieu Patou <mat@matws.net>
Fri, 5 Aug 2011 19:13:08 +0000 (23:13 +0400)
committerMatthieu Patou <mat@matws.net>
Fri, 5 Aug 2011 21:33:07 +0000 (01:33 +0400)
pidl/lib/Parse/Pidl/Wireshark/NDR.pm

index b54b8f0af06215a8e7d40b98dbb0d2259ff41ff4..45b6c1e5f699ee6cc0309bd7378c0e3eae9e7606 100644 (file)
@@ -639,7 +639,7 @@ sub Struct($$$$)
        $self->pidl_code("int old_offset;");
        $self->pidl_code("");
 
-       if ($e->{ALIGN} > 1) {
+       if ($e->{ALIGN} > 1 and not property_matches($e, "flag", ".*LIBNDR_FLAG_NOALIGN.*")) {
                $self->pidl_code("ALIGN_TO_$e->{ALIGN}_BYTES;");
        }
        $self->pidl_code("");