diff options
-rw-r--r-- | source4/build/pidl/util.pm | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/source4/build/pidl/util.pm b/source4/build/pidl/util.pm index 8331e115d3..b732c185b2 100644 --- a/source4/build/pidl/util.pm +++ b/source4/build/pidl/util.pm @@ -68,7 +68,10 @@ sub CleanData($) if (ref($v) eq "ARRAY") { foreach my $i (0 .. $#{$v}) { CleanData($v->[$i]); - if (ref($v->[$i]) eq "ARRAY" && $#{$v->[$i]}==-1) { delete($v->[$i]); next; } + if (ref($v->[$i]) eq "ARRAY" && $#{$v->[$i]}==-1) { + $v->[$i] = undef; + next; + } } # this removes any undefined elements from the array @{$v} = grep { defined $_ } @{$v}; |