Does XSL Leak File Handles?

Does XSL Leak File Handles?

No, but it may appear to in some use cases. If you use redirect:write a lot for example:

   <redirect:write file="{$outfile}">
   ...
   </redirect:write>

The solution here is to bracket the write with open and close so that the engine does not have to implicitly track the open file stream:

   <redirect:open file="{$outfile}"/>
   <redirect:write file="{$outfile}">
   ...
   </redirect:write>
   <redirect:close file="{$outfile}"/>

Posted in Computing, Software Development, Web. Comments Off

Comments are closed.