Index: Setup/updateFileInfo.tcl ================================================================== --- Setup/updateFileInfo.tcl +++ Setup/updateFileInfo.tcl @@ -99,10 +99,11 @@ href=".*?/package/.*?/\d+\.\d+\.\d+\.\d+">(.*?).*?\((\d+?\.\d+?)\ MiB\).*?sha1: ([0-9A-F]{40})} set pattern3 {href="/downloads/(.*?)"} set pattern4 {\(sha1: ([0-9A-F]{40})\)} +set pattern5 {\((\d+?\.\d+?) MiB\)} # # NOTE: Grab all the data from the file to be updated. # set data [readFile $updateFileName] @@ -186,11 +187,12 @@ # # NOTE: Attempt to verify that each file name now has the correct SHA1 hash # associated with it on the page. # foreach {dummy3 fileName} [regexp -all -inline -nocase -- $pattern3 $data] \ - {dummy4 fileHash} [regexp -all -inline -nocase -- $pattern4 $data] { + {dummy4 fileHash} [regexp -all -inline -nocase -- $pattern4 $data] \ + {dummy5 fileSize} [regexp -all -inline -nocase -- $pattern5 $data] { # # NOTE: Get the fully qualified file name based on the configured # directory. # set fullFileName [file join $outputDirectory [file tail $fileName]] @@ -204,10 +206,18 @@ if {$fileHash ne $fullFileHash} then { puts stdout "ERROR: SHA1 hash mismatch for\ file \"$fullFileName\", have \"$fileHash\" (from data),\ need \"$fullFileHash\" (calculated)." } + + set fullFileSize [getFileSize $fullFileName] + + if {$fileSize ne $fullFileSize} then { + puts stdout "ERROR: Byte size mismatch for\ + file \"$fullFileName\", have \"$fileSize\" (from data),\ + need \"$fullFileSize\" (calculated)." + } } # # NOTE: Write the [modified] data to the file to be updated. # Index: www/downloads.wiki ================================================================== --- www/downloads.wiki +++ www/downloads.wiki @@ -2120,12 +2120,10 @@