diff options
Diffstat (limited to 'usr/src/tools/scripts/git-pbchk.py')
-rw-r--r-- | usr/src/tools/scripts/git-pbchk.py | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/usr/src/tools/scripts/git-pbchk.py b/usr/src/tools/scripts/git-pbchk.py index fd16e109b2..def3b2617e 100644 --- a/usr/src/tools/scripts/git-pbchk.py +++ b/usr/src/tools/scripts/git-pbchk.py @@ -19,6 +19,7 @@ # Copyright 2008, 2012 Richard Lowe # Copyright 2014 Garrett D'Amore <garrett@damore.org> # Copyright (c) 2014, Joyent, Inc. +# Copyright (c) 2015 by Delphix. All rights reserved. # import getopt @@ -163,7 +164,9 @@ def git_file_list(parent, paths=None): ret = set() for fname in p: - if fname and not fname.isspace() and fname not in ret: + res = git("diff %s HEAD %s" % (parent, fname)) + empty = not res.readline() + if fname and not fname.isspace() and fname not in ret and not empty: ret.add(fname.strip()) return ret |