Ignore:
Timestamp:
11/16/08 20:26:12 (4 years ago)
Author:
OlivierRaginel
Message:

Item38: Make use of sandbox

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/EmbedBibPlugin/lib/TWiki/Plugins/EmbedBibPlugin.pm

    r529 r742  
    172172    } 
    173173 
    174  
     174    my $sandbox = $TWiki::sharedSandbox || $TWiki::sandbox; 
    175175    if ( $Style eq "bibtex" ) 
    176176    { 
    177         return `$bibtoolcommand`; 
     177        return $sandbox->sysCommand( $bibtoolcommand ); 
    178178    } 
    179179    elsif ( $Style eq "html" ) 
     
    211211        # input from stdin 
    212212        open(TMPFILE, ">$tmpBibFile") or return "EMBEDBIB Error: fatal error"; 
    213         my $tmpOut = `$bibtoolcommand`; 
     213        my $tmpOut = $sandbox->sysCommand( $bibtoolcommand ); 
    214214        print TMPFILE $tmpOut; 
    215215        print TMPFILE $bibtex2htmlConf; 
    216  
    217         return `$bibtex2htmlPath $tmpBibFile $bibtex2htmlArgs `; 
     216        close TMPFILE; 
     217 
     218        $tmpOut = $sandbox->sysCommand( "$bibtex2htmlPath $tmpBibFile $bibtex2htmlArgs" ); 
     219        unlink $tmpBibFile; 
     220        return $tmpOut; 
    218221    } 
    219222} 
Note: See TracChangeset for help on using the changeset viewer.