From 4a8ceb8c56c66059791e4ef74ef3cbef4259f961 Mon Sep 17 00:00:00 2001 From: Jelmer Vernooij Date: Sun, 13 Jan 2008 15:11:28 +0100 Subject: pidl/python: Fix bug accidently filling in the body of enums/bitmaps without body. (This used to be commit 97971f0d8080f3934ea5940cc0f230004afb94a1) --- source4/pidl/lib/Parse/Pidl/Samba4/Python.pm | 2 ++ 1 file changed, 2 insertions(+) diff --git a/source4/pidl/lib/Parse/Pidl/Samba4/Python.pm b/source4/pidl/lib/Parse/Pidl/Samba4/Python.pm index ae4931571a..d0a5bbd7e3 100644 --- a/source4/pidl/lib/Parse/Pidl/Samba4/Python.pm +++ b/source4/pidl/lib/Parse/Pidl/Samba4/Python.pm @@ -79,6 +79,8 @@ sub EnumAndBitmapConsts($$$) { my ($self, $name, $d) = @_; + return unless (defined($d->{ELEMENTS})); + foreach my $e (@{$d->{ELEMENTS}}) { $e =~ /^([A-Za-z0-9_]+)=(.*)$/; my $cname = $1; -- cgit