# HG changeset patch # User Martin von Zweigbergk # Date 1573769256 28800 # Node ID 47d983f0af65d1f8fa281f7ed8fe23b0d5c40546 # Parent ef43765c921d4980b1ec698fc9c15921212b5528 py3: drop an unnecessary fsencode() before comparing with constant Differential Revision: https://phab.mercurial-scm.org/D7413 diff -r ef43765c921d -r 47d983f0af65 mercurial/utils/procutil.py --- a/mercurial/utils/procutil.py Thu Nov 14 14:03:02 2019 -0800 +++ b/mercurial/utils/procutil.py Thu Nov 14 14:07:36 2019 -0800 @@ -288,10 +288,7 @@ _sethgexecutable(pycompat.sysexecutable) elif ( not pycompat.iswindows - and os.path.basename( - pycompat.fsencode(getattr(mainmod, '__file__', '')) - ) - == b'hg' + and os.path.basename(getattr(mainmod, '__file__', '')) == 'hg' ): _sethgexecutable(pycompat.fsencode(mainmod.__file__)) else: