[Lxr-dev] [ lxr-Bugs-2714744 ] Tagger & Plain.pm inefficient
Brought to you by:
ajlittoz
From: SourceForge.net <no...@so...> - 2012-03-29 19:06:14
|
Bugs item #2714744, was opened at 2009-03-26 08:43 Message generated for change (Settings changed) made by ajlittoz You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=390117&aid=2714744&group_id=27350 Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: genxref Group: current cvs >Status: Closed >Resolution: Fixed Priority: 3 Private: No Submitted By: Malcolm Box (mbox) >Assigned to: Andre-Littoz (ajlittoz) Summary: Tagger & Plain.pm inefficient Initial Comment: Tagger.pm uses Files::tmpfile to get a file for indexing. In the plain file case, this is created by copying the existing file into a temporary file. After indexing the temporary file is then deleted. Should fix the interface from Tagger.pm to Files.pm to simply get a read-only reference to the file, and close it when no longer needed. Leave it up to Files.pm to worry about where/how it's on the disk. Alternatively on Unix systems Plain.pm could just create a hardlink and give that back to Tagger.pm, but this isn't portable. ---------------------------------------------------------------------- >Comment By: Andre-Littoz (ajlittoz) Date: 2012-03-29 12:06 Message: Files.pm interface changed as follows: - method tmpfile renames to realfilename to return a filename containing text requested as file and version - new method releaserealfilename to tell when the real filename is no longer needed. Plain.pm: - realfilename returns the OS absolute path to the requested file version - releaserealfilename does nothing CVS.pm, BK.pm (this one on a guess, result not tested) - realfilename makes a temp copy of the requested file version and returns the OS absolute path of the temp file -releaserealfilename deletes the temps file Git.pm: no fix because Git support is broken in CPAN library. ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=390117&aid=2714744&group_id=27350 |