de-fuzz python-keyring patch

With rpm version < 4.13, patch cmd will create .orig file for fuzzy
patch in default. And this .orig file may lead to rpmbuild failure
"error: Installed (but unpackaged) file(s) found:"

Please visit below link to get more detail info:
https://bugs.launchpad.net/starlingx/+bug/1794611

Story: 2003917
Task: 26817

Change-Id: I455087544161e38160608b1fba27e00584c61feb
Signed-off-by: slin14 <shuicheng.lin@intel.com>
This commit is contained in:
slin14 2018-10-09 23:07:55 +08:00
parent d1002da928
commit 3533354c69
1 changed files with 12 additions and 12 deletions

View File

@ -1,8 +1,8 @@
Index: keyring-3.2/keyring/backends/file.py diff --git a/keyring/backends/file.py b/keyring/backends/file.py
=================================================================== index f899880..ef6db1d 100644
--- keyring-3.2.orig/keyring/backends/file.py --- a/keyring/backends/file.py
+++ keyring-3.2/keyring/backends/file.py +++ b/keyring/backends/file.py
@@ -114,7 +114,7 @@ class BaseKeyring(KeyringBackend): @@ -116,7 +116,7 @@ class BaseKeyring(FileBacked, KeyringBackend):
# create the file without group/world permissions # create the file without group/world permissions
with open(self.file_path, 'w'): with open(self.file_path, 'w'):
pass pass
@ -11,7 +11,7 @@ Index: keyring-3.2/keyring/backends/file.py
os.chmod(self.file_path, user_read_write) os.chmod(self.file_path, user_read_write)
def delete_password(self, service, username): def delete_password(self, service, username):
@@ -188,12 +188,19 @@ class EncryptedKeyring(BaseKeyring): @@ -172,12 +172,19 @@ class Encrypted(object):
def _get_new_password(self): def _get_new_password(self):
while True: while True:
@ -37,7 +37,7 @@ Index: keyring-3.2/keyring/backends/file.py
if '' == password.strip(): if '' == password.strip():
# forbid the blank password # forbid the blank password
sys.stderr.write("Error: blank passwords aren't allowed.\n") sys.stderr.write("Error: blank passwords aren't allowed.\n")
@@ -233,8 +240,15 @@ class EncryptedKeyring(BaseKeyring): @@ -248,8 +255,15 @@ class EncryptedKeyring(Encrypted, BaseKeyring):
Unlock this keyring by getting the password for the keyring from the Unlock this keyring by getting the password for the keyring from the
user. user.
""" """
@ -55,11 +55,11 @@ Index: keyring-3.2/keyring/backends/file.py
try: try:
ref_pw = self.get_password('keyring-setting', 'password reference') ref_pw = self.get_password('keyring-setting', 'password reference')
assert ref_pw == 'password reference value' assert ref_pw == 'password reference value'
Index: keyring-3.2/keyring/util/platform_.py diff --git a/keyring/util/platform_.py b/keyring/util/platform_.py
=================================================================== index dcdffea..53b9eae 100644
--- keyring-3.2.orig/keyring/util/platform_.py --- a/keyring/util/platform_.py
+++ keyring-3.2/keyring/util/platform_.py +++ b/keyring/util/platform_.py
@@ -16,7 +16,7 @@ def _data_root_Linux(): @@ -19,7 +19,7 @@ def _data_root_Linux():
Use freedesktop.org Base Dir Specfication to determine storage Use freedesktop.org Base Dir Specfication to determine storage
location. location.
""" """