[sword-svn] r423 - trunk/modules/perlconverters

chrislit at crosswire.org chrislit at crosswire.org
Sun Jun 9 20:56:49 MST 2013


Author: chrislit
Date: 2013-06-09 20:56:49 -0700 (Sun, 09 Jun 2013)
New Revision: 423

Modified:
   trunk/modules/perlconverters/usfm2osis.pl
Log:
corrected ampersand (&) handling (without mangling pre-escaped sequences) for MODTOOLS-37

Modified: trunk/modules/perlconverters/usfm2osis.pl
===================================================================
--- trunk/modules/perlconverters/usfm2osis.pl	2013-06-10 03:32:27 UTC (rev 422)
+++ trunk/modules/perlconverters/usfm2osis.pl	2013-06-10 03:56:49 UTC (rev 423)
@@ -4,7 +4,7 @@
 
 ## Licensed under the standard BSD license:
 
-# Copyright (c) 2002-2012 CrossWire Bible Society <http://www.crosswire.org/>
+# Copyright (c) 2002-2013 CrossWire Bible Society <http://www.crosswire.org/>
 # All rights reserved.
 #
 # Redistribution and use in source and binary forms, with or without
@@ -242,7 +242,7 @@
 	$line = @filedata[$i];
 
 	### Basic XML entity encoding
-	$line =~ s/&(?![a-zA-Z0-9])/&amp;/g;
+	$line =~ s/&(?![a-zA-Z0-9]+;)/&amp;/g;
 #	$line =~ s/<< ?/\@/g;
 #	$line =~ s/>>/\#/g;
 #	$line =~ s/</\$/g;




More information about the sword-cvs mailing list