Skip to content

Commit 7e84122

Browse files
yarikopticByron
authored andcommitted
BF: there is no exc variable, raising NotASurrogateError if that is the right thing todo
1 parent 72dddc7 commit 7e84122

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

git/compat.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -204,7 +204,7 @@ def replace_surrogate_encode(mystring):
204204
# The following magic comes from Py3.3's Python/codecs.c file:
205205
if not 0xD800 <= code <= 0xDCFF:
206206
# Not a surrogate. Fail with the original exception.
207-
raise exc
207+
raise NotASurrogateError
208208
# mybytes = [0xe0 | (code >> 12),
209209
# 0x80 | ((code >> 6) & 0x3f),
210210
# 0x80 | (code & 0x3f)]

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy