]> thyrsus.com Git - imgsizer.git/commitdiff
tidy fix.
authorEric S. Raymond <esr@thyrsus.com>
Sat, 15 Nov 2003 15:45:43 +0000 (15:45 +0000)
committerEric S. Raymond <esr@thyrsus.com>
Sat, 15 Nov 2003 15:45:43 +0000 (15:45 +0000)
imgsizer

index 3ee339e614e650feec7601de2fb288d4a771c10b..50336fd169270ccc695fa55fde4ca93965c20660 100755 (executable)
--- a/imgsizer
+++ b/imgsizer
@@ -64,6 +64,8 @@
 # Enhancement by ESR, 14 Nov 2003
 #
 #    Verify and merge Lucien Saviot's patch to produce XHTML from XHTML input.
+#    Also his change to handle spurious lin e breaks produced by Dave Raggett's
+#    tidy(1) utility.
 
 import sys, os, getopt, string, re, urllib, commands
 
@@ -188,7 +190,7 @@ def imgsize(src):
     # All attempts failed
     sys.stderr.write("imgsizer: couldn't analyze %s\n" % src)
 
-source  = re.compile('SRC="?([^" \t\n]*)"?', re.I)
+source  = re.compile('SRC\s*=\s*"?([^" \t\n]*)"?', re.I)
 awidth  = re.compile(r' *WIDTH\s*=\s*"?[0-9]*"?', re.I)
 aheight = re.compile(r' *HEIGHT\s*=\s*"?[0-9]*"?', re.I)
 pwidth  = re.compile(r'WIDTH\s*=\s*"?[0-9]*%"?', re.I)