about summary refs log tree commit diff
path: root/filters
diff options
context:
space:
mode:
authorChristian Hesse <mail@eworm.de>2014-01-14 11:11:23 +0100
committerJason A. Donenfeld <Jason@zx2c4.com>2014-01-14 13:55:35 +0100
commit46176eca7f130a59813d160415a5ead58133f128 (patch)
treeb428c8d1ebc032a74b5bf3945b094db57e1a370e /filters
parentemail-gravatar.lua: fix for lua 5.2 (diff)
downloadcgit-pink-46176eca7f130a59813d160415a5ead58133f128.tar.gz
cgit-pink-46176eca7f130a59813d160415a5ead58133f128.zip
email-gravatar.py: fix UTF-8
Diffstat (limited to 'filters')
-rwxr-xr-xfilters/email-gravatar.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/filters/email-gravatar.py b/filters/email-gravatar.py
index f90b87d..5d08ea8 100755
--- a/filters/email-gravatar.py
+++ b/filters/email-gravatar.py
@@ -20,6 +20,7 @@
 
 import sys
 import hashlib
+import codecs
 
 email = sys.argv[1].lower().strip()
 if email[0] == '<':
@@ -29,6 +30,9 @@ if email[-1] == '>':
 
 page = sys.argv[2]
 
+sys.stdin = codecs.getreader("utf-8")(sys.stdin.detach())
+sys.stdout = codecs.getwriter("utf-8")(sys.stdout.detach())
+
 md5 = hashlib.md5(email.encode()).hexdigest()
 text = sys.stdin.read().strip()
 
03fbdd28a3781fb876a9d6b674ce243fbb035c&follow=1'>tls: Replace ECDSA_METHOD with EC_KEY_METHODJune McEnroe 2022-02-27Import LibreSSL 3.5.0June McEnroe 2021-11-29tls: Revert accidentally(?) reverted upstream 3.4.2June McEnroe 2021-11-29Import LibreSSL 3.4.2June McEnroe 2021-10-14Import LibreSSL 3.4.1June McEnroe 2021-09-17Import LibreSSL 3.4.0June McEnroe 2021-08-24Import LibreSSL 3.3.4June McEnroe 2021-05-25Bump version to 3.3.3p1 3.3.3p1June McEnroe 2021-05-25build: Add scripts to EXTRA_DISTJune McEnroe 2021-05-25import: Add missing scripts/wrap-compiler-for-flag-checkJune McEnroe 2021-05-08Import LibreSSL 3.3.3June McEnroe 2021-04-18build: Remove added x509_verify.3 links 3.3.2June McEnroe 2021-04-18tls: Use EC_KEY_set_ex_dataJune McEnroe 2021-04-18Import LibreSSL 3.3.2June McEnroe 2021-03-05Bump version to 3.3.1p1 3.3.1p1June McEnroe 2021-03-05build: Add OpenSSL includes to libcompatJune McEnroe Some compat sources (getentropy_linux.c for example) require OpenSSL. Reported by Robert Scheck. 2020-12-15Import LibreSSL 3.3.1June McEnroe 2020-11-24Import LibreSSL 3.3.0June McEnroe 2020-10-22Import LibreSSL 3.2.2June McEnroe 2020-09-29Import LibreSSL 3.2.1June McEnroe 2020-09-29import: Add m4/ax_add_fortify_source.m4June McEnroe 2020-08-05build: Add README.7 to EXTRA_DIST 3.2.0June McEnroe 2020-08-03doc: Indicate that only OpenSSL 1.1.1b and newer workJune McEnroe