cmdutil: use isstdiofilename() where appropriate
authorYuya Nishihara <yuya@tcha.org>
Thu, 01 Jun 2017 23:08:23 +0900
changeset 32618 d3e1c5b4986c
parent 32617 e48cb1c7a902
child 32619 d110fb58424c
cmdutil: use isstdiofilename() where appropriate
mercurial/cmdutil.py
--- a/mercurial/cmdutil.py	Thu Jun 01 23:05:29 2017 +0900
+++ b/mercurial/cmdutil.py	Thu Jun 01 23:08:23 2017 +0900
@@ -493,7 +493,7 @@
                            'exclusive'))
     if not message and logfile:
         try:
-            if logfile == '-':
+            if isstdiofilename(logfile):
                 message = ui.fin.read()
             else:
                 message = '\n'.join(util.readfile(logfile).splitlines())