r12191 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r12190‎ | r12191 | r12192 >
Date:08:04, 21 December 2005
Author:avar
Status:old
Tags:
Comment:
* Don't consider a file binary if the first five lines contain a character
above chr(127) or below ' ' (32) but just check whether the first five
contain a character below ' ', this should fix files being marked as binary
due to them containing multibyte characters such as three characters in my
name.

* http://mail.wikimedia.org/pipermail/wikitech-l/2005-December/033184.html
Modified paths:
  • /trunk/CVSROOT/syncmail (modified) (history)

Diff [purge]

Index: trunk/CVSROOT/syncmail
@@ -168,7 +168,7 @@
169169 for c in line.rstrip():
170170 if c.isspace():
171171 continue
172 - if c < ' ' or c > chr(127):
 172+ if c < ' ':
173173 lines = BINARY_EXPLANATION_LINES[:]
174174 break
175175 lines.insert(0, '--- NEW FILE: %s ---\n' % file)

Status & tagging log