From 536c7acd13426d42dc863ae8b50e6c3a4cb2e858 Mon Sep 17 00:00:00 2001 From: Maximilian Hils Date: Fri, 1 Jul 2016 14:10:48 -0700 Subject: py3++ --- netlib/strutils.py | 10 ---------- 1 file changed, 10 deletions(-) (limited to 'netlib/strutils.py') diff --git a/netlib/strutils.py b/netlib/strutils.py index 5ad41c7e..ca6eaa42 100644 --- a/netlib/strutils.py +++ b/netlib/strutils.py @@ -1,4 +1,3 @@ -import re import unicodedata import codecs @@ -56,15 +55,6 @@ def clean_bin(s, keep_spacing=True): ) -def safe_subn(pattern, repl, target, *args, **kwargs): - """ - There are Unicode conversion problems with re.subn. We try to smooth - that over by casting the pattern and replacement to strings. We really - need a better solution that is aware of the actual content ecoding. - """ - return re.subn(str(pattern), str(repl), target, *args, **kwargs) - - def bytes_to_escaped_str(data): """ Take bytes and return a safe string that can be displayed to the user. -- cgit v1.2.3