CVS: ht2html LinkFixer.py,2.1,2.2

"A.M. Kuchling" <[email protected]> Sat, 13 Sep 2003 05:29:50 -0700
Newsgroups gmane.comp.web.ht2html.devel
Message-ID <[email protected]>
Update of /cvsroot/ht2html/ht2html
In directory sc8-pr-cvs1:/tmp/cvs-serv16072

Modified Files:
	LinkFixer.py 
Log Message:
Fix for bug reported by Brett C.: normpath() would turn '../../pics' into 'pics'.  
'..' should only remove the previous path segment if that segment isn't also '..'.


Index: LinkFixer.py
===================================================================
RCS file: /cvsroot/ht2html/ht2html/LinkFixer.py,v
retrieving revision 2.1
retrieving revision 2.2
diff -C2 -d -r2.1 -r2.2
*** LinkFixer.py	12 Aug 2003 16:10:19 -0000	2.1
--- LinkFixer.py	13 Sep 2003 12:29:48 -0000	2.2
***************
*** 108,112 ****
          if p == '.':
              continue
!         if p == '..' and len(parts) > 0:
              del parts[-1]
              continue
--- 108,112 ----
          if p == '.':
              continue
!         if p == '..' and len(parts) > 0 and parts[-1] != '..':
              del parts[-1]
              continue



-------------------------------------------------------
This SF.net email is sponsored by: SF.net Giveback Program.
SourceForge.net hosts over 70,000 Open Source Projects.
See the people who have HELPED US provide better services:
Click here: http://sourceforge.net/supporters.php