summaryrefslogtreecommitdiff
path: root/source4/pidl
diff options
context:
space:
mode:
authorJulien Kerihuel <j.kerihuel@openchange.org>2008-05-31 00:47:14 +0200
committerStefan Metzmacher <metze@samba.org>2008-06-27 12:43:04 +0200
commit0c6ce977ffb8f53f546596b76c1e0858cc6a88ba (patch)
tree4384190bc3ef699f9e0be579f07019780eb5fe13 /source4/pidl
parentf5604ebd618446318efb27cc62276e636908035e (diff)
downloadsamba-0c6ce977ffb8f53f546596b76c1e0858cc6a88ba.tar.gz
samba-0c6ce977ffb8f53f546596b76c1e0858cc6a88ba.tar.bz2
samba-0c6ce977ffb8f53f546596b76c1e0858cc6a88ba.zip
Fix if_version for interfaces with a if_version_minor field different from 0
Signed-off-by: Stefan Metzmacher <metze@samba.org> (This used to be commit 7b6927832a1118b142d0d8a3a5548761f5a04f1a)
Diffstat (limited to 'source4/pidl')
-rw-r--r--source4/pidl/lib/Parse/Pidl/NDR.pm7
1 files changed, 6 insertions, 1 deletions
diff --git a/source4/pidl/lib/Parse/Pidl/NDR.pm b/source4/pidl/lib/Parse/Pidl/NDR.pm
index 33e5ad3196..1e4504764a 100644
--- a/source4/pidl/lib/Parse/Pidl/NDR.pm
+++ b/source4/pidl/lib/Parse/Pidl/NDR.pm
@@ -688,7 +688,12 @@ sub ParseInterface($)
$version = "0.0";
if(defined $idl->{PROPERTIES}->{version}) {
- $version = $idl->{PROPERTIES}->{version};
+ my @if_version = split(/\./, $idl->{PROPERTIES}->{version});
+ if ($if_version[0] == $idl->{PROPERTIES}->{version}) {
+ $version = $idl->{PROPERTIES}->{version};
+ } else {
+ $version = $if_version[1] << 16 | $if_version[0];
+ }
}
# If no endpoint is set, default to the interface name as a named pipe