mirror of
https://github.com/valitydev/salt.git
synced 2024-11-07 17:09:03 +00:00
Merge pull request #40648 from terminalmage/py3-gitfs-fix
Fix gitfs' write_file functions for Python 3
This commit is contained in:
commit
892d9a5511
@ -1153,7 +1153,7 @@ class GitPython(GitProvider):
|
||||
'''
|
||||
Using the blob object, write the file to the destination path
|
||||
'''
|
||||
with salt.utils.fopen(dest, 'w+') as fp_:
|
||||
with salt.utils.fopen(dest, 'wb+') as fp_:
|
||||
blob.stream_data(fp_)
|
||||
|
||||
|
||||
@ -1819,7 +1819,7 @@ class Pygit2(GitProvider):
|
||||
'''
|
||||
Using the blob object, write the file to the destination path
|
||||
'''
|
||||
with salt.utils.fopen(dest, 'w+') as fp_:
|
||||
with salt.utils.fopen(dest, 'wb+') as fp_:
|
||||
fp_.write(blob.data)
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user