diff options
author | Andy Fiddaman <omnios@citrus-it.co.uk> | 2020-01-08 10:23:12 +0000 |
---|---|---|
committer | Andy Fiddaman <omnios@citrus-it.co.uk> | 2020-01-08 22:13:50 +0000 |
commit | 1081175181bc5c4495f7bc7f565bf3af4f1d6085 (patch) | |
tree | a83cce1dbe3a9814d420428d9f871ccdf77382fa /usr/src/tools/scripts/git-pbchk.py | |
parent | d2f7972d81337947df76c36b8c2a5f290829fa7a (diff) | |
download | illumos-gate-1081175181bc5c4495f7bc7f565bf3af4f1d6085.tar.gz |
12171 pbchk traceback when checking .java file under python3
Reviewed by: Toomas Soome <tsoome@me.com>
Reviewed by: John Levon <john.levon@joyent.com>
Approved by: Dan McDonald <danmcd@joyent.com>
Diffstat (limited to 'usr/src/tools/scripts/git-pbchk.py')
-rw-r--r-- | usr/src/tools/scripts/git-pbchk.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/usr/src/tools/scripts/git-pbchk.py b/usr/src/tools/scripts/git-pbchk.py index 99bce29087..ec01255c6e 100644 --- a/usr/src/tools/scripts/git-pbchk.py +++ b/usr/src/tools/scripts/git-pbchk.py @@ -21,7 +21,7 @@ # Copyright (c) 2015, 2016 by Delphix. All rights reserved. # Copyright 2016 Nexenta Systems, Inc. # Copyright (c) 2019, Joyent, Inc. -# Copyright 2019 OmniOS Community Edition (OmniOSce) Association. +# Copyright 2020 OmniOS Community Edition (OmniOSce) Association. # from __future__ import print_function @@ -280,7 +280,7 @@ def jstyle(root, parent, flist, output): ret = 0 output.write("Java style:\n") for f in flist(lambda x: x.endswith('.java')): - with io.open(f, encoding='utf-8', errors='replace') as fh: + with io.open(f, mode='rb') as fh: ret |= JStyle.jstyle(fh, output=output, picky=True) return ret |