]> jfr.im git - irc/xchat.git/commitdiff
Always use the full path for __FILE__
authorlsitu <redacted>
Sat, 6 Feb 2010 22:15:45 +0000 (22:15 +0000)
committerlsitu <redacted>
Sat, 6 Feb 2010 22:15:45 +0000 (22:15 +0000)
git-svn-id: svn://svn.code.sf.net/p/xchat/svn@1395 893a96be-7f27-4fdf-9d1e-6aeec9d3cce1

plugins/perl/Xchat.pm

index 2cd33e361a70d29ee33b326fe8eeb517a5749b70..9c7654fa5fb59710aebb3faea0d6e9f24bdb5e30 100644 (file)
@@ -524,7 +524,8 @@ sub load {
                $scripts{$package}{loaded_at} = Time::HiRes::time();
                {
                        no strict; no warnings;
-                       $source =~ s/^/#line 1 "$file"\n\x7Bpackage $package;/;
+                       my $full_path = File::Spec->rel2abs( $file );
+                       $source =~ s/^/#line 1 "$full_path"\n\x7Bpackage $package;/;
 
                        # make sure we add the closing } even if the last line is a comment
                        if( $source =~ /^#.*\Z/m ) {