From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received-SPF: Pass (sender SPF authorized) identity=mailfrom; client-ip=195.135.221.5; helo=smtp.nue.novell.com; envelope-from=glin@suse.com; receiver=edk2-devel@lists.01.org Received: from smtp.nue.novell.com (smtp.nue.novell.com [195.135.221.5]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ml01.01.org (Postfix) with ESMTPS id 98B9B21E0B9E2 for ; Thu, 1 Feb 2018 00:31:27 -0800 (PST) Received: from localhost.localdomain (unknown.telstraglobal.net [134.159.103.118]) by smtp.nue.novell.com with ESMTP (NOT encrypted); Thu, 01 Feb 2018 09:37:01 +0100 From: Gary Lin To: edk2-devel@lists.01.org Cc: Yonghong Zhu , Liming Gao Date: Thu, 1 Feb 2018 16:36:00 +0800 Message-Id: <20180201083608.16036-13-glin@suse.com> X-Mailer: git-send-email 2.16.1 In-Reply-To: <20180201083608.16036-1-glin@suse.com> References: <20180201083608.16036-1-glin@suse.com> Subject: [PATCH v2 12/20] BaseTools: Migrate to the new octal literal X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 01 Feb 2018 08:31:28 -0000 Change the octal literals according to PEP3127 https://www.python.org/dev/peps/pep-3127/ Contributed-under: TianoCore Contribution Agreement 1.1 Cc: Yonghong Zhu Cc: Liming Gao Signed-off-by: Gary Lin --- BaseTools/Source/Python/Common/LongFilePathOs.py | 2 +- BaseTools/Source/Python/UPT/Core/FileHook.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/BaseTools/Source/Python/Common/LongFilePathOs.py b/BaseTools/Source/Python/Common/LongFilePathOs.py index 2e530f9dd774..47d63faeb995 100644 --- a/BaseTools/Source/Python/Common/LongFilePathOs.py +++ b/BaseTools/Source/Python/Common/LongFilePathOs.py @@ -33,7 +33,7 @@ def rmdir(path): def mkdir(path): return os.mkdir(LongFilePath(path)) -def makedirs(name, mode=0777): +def makedirs(name, mode=0o777): return os.makedirs(LongFilePath(name), mode) def rename(old, new): diff --git a/BaseTools/Source/Python/UPT/Core/FileHook.py b/BaseTools/Source/Python/UPT/Core/FileHook.py index d8736a872366..67e86f4f7454 100644 --- a/BaseTools/Source/Python/UPT/Core/FileHook.py +++ b/BaseTools/Source/Python/UPT/Core/FileHook.py @@ -166,7 +166,7 @@ def _hookrm(path): else: __built_in_remove__(path) -def _hookmkdir(path, mode=0777): +def _hookmkdir(path, mode=0o777): if GlobalData.gRECOVERMGR: GlobalData.gRECOVERMGR.bkmkdir(path, mode) else: -- 2.16.1