diff options
Diffstat (limited to 'source4/pidl/idl.yp')
-rw-r--r-- | source4/pidl/idl.yp | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/source4/pidl/idl.yp b/source4/pidl/idl.yp index ef0ec203a7..430f7e1b06 100644 --- a/source4/pidl/idl.yp +++ b/source4/pidl/idl.yp @@ -330,6 +330,7 @@ sub CleanData($) { sub CleanData($); my($v) = shift; + return undef if (not defined($v)); if (ref($v) eq "ARRAY") { foreach my $i (0 .. $#{$v}) { CleanData($v->[$i]); @@ -416,12 +417,13 @@ again: } } -sub parse_string($) +sub parse_string { - my ($data) = @_; + my ($data,$filename) = @_; my $self = new Parse::Pidl::IDL; + $self->YYData->{INPUT_FILENAME} = $filename; $self->YYData->{INPUT} = $data; $self->YYData->{LINE} = 0; $self->YYData->{LAST_TOKEN} = "NONE"; @@ -444,5 +446,5 @@ sub parse_file($) my $data = `$cpp -D__PIDL__ -xc $filename`; $/ = $saved_delim; - return parse_string($data); + return parse_string($data, $filename); } |