Salome HOME
Merge branch 'omu/SalomeLauncher'
[modules/kernel.git] / src / KERNEL_PY / kernel / syshelper.py
index eb83e7966b546e81f7f8951fdb41422c2e07abde..dd7c9f8e2ad5577fb5762807e4d987891e1b76f2 100644 (file)
@@ -1,5 +1,5 @@
 # -*- coding: iso-8859-1 -*-
-# Copyright (C) 2007-2014  CEA/DEN, EDF R&D, OPEN CASCADE
+# Copyright (C) 2007-2015  CEA/DEN, EDF R&D, OPEN CASCADE
 #
 # Copyright (C) 2003-2007  OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
 # CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
@@ -25,7 +25,7 @@ __author__="gboulant"
 __date__ ="$21 mai 2010 18:00:23$"
 
 
-def findFiles(rootpath, excludes=[]):
+def findFiles(rootpath, excludes=None):
     """
     This looks after files recursively from the specified rootpath,
     but without visiting directories whose basename is in the list
@@ -34,6 +34,8 @@ def findFiles(rootpath, excludes=[]):
     if not os.path.exists(rootpath):
         raise RuntimeError("the path %s does not exists"%rootpath)
 
+    if excludes is None:
+        excludes = []
     exclude_options=""
     for excludepath in excludes:
         exclude_options+="-e %s "%excludepath