From: Yoshitaka Aharen Date: Thu, 15 Nov 2012 09:15:28 +0000 (+0900) Subject: [2157] change need_generate condition X-Git-Tag: bind10-1.1.0beta1-release~85^2~5^2~111 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=c30ebf9ecc8b18a7b2e6ae57f6e8db582acb00c7;p=thirdparty%2Fkea.git [2157] change need_generate condition regenerate the file if .pre file is updated --- diff --git a/src/bin/auth/gen-statistics_items.py.pre.in b/src/bin/auth/gen-statistics_items.py.pre.in index e42e109ee6..816e426811 100755 --- a/src/bin/auth/gen-statistics_items.py.pre.in +++ b/src/bin/auth/gen-statistics_items.py.pre.in @@ -34,7 +34,9 @@ def need_generate(filepath, mtime): To avoid unnecessary compilation, we skip (re)generating the file when the file already exists and newer than the base file. ''' - if os.path.exists(filepath) and os.path.getmtime(filepath) > mtime: + if os.path.exists(filepath) and\ + (os.path.getmtime(filepath) > mtime or + os.path.getmtime(filepath) > os.path.getmtime(filepath+pre_suffix)): return False return True