Skip to content
This repository has been archived by the owner on Nov 4, 2018. It is now read-only.

Commit

Permalink
Browse files Browse the repository at this point in the history
Fixed Python 2.4 after conversion to 'hashlib'
git-svn-id: https://s3tools.svn.sourceforge.net/svnroot/s3tools/s3cmd/trunk@324 830e0280-6d2a-0410-9c65-932aecc39d9d
  • Loading branch information
W. Tell committed Dec 31, 2008
1 parent 3c68245 commit 6fa688f
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion ChangeLog
@@ -1,7 +1,7 @@
2009-01-01 W. Tell <w_tell -at- sourceforge>

* S3/S3.py, S3/Utils.py: Use 'hashlib' instead of md5 and sha
modules to avoid Python 2.6 warnings.
modules to avoid Python 2.6 warnings.

2008-12-31 Michal Ludvig <michal@logix.cz>

Expand Down
2 changes: 1 addition & 1 deletion S3/S3.py
Expand Up @@ -17,7 +17,7 @@
from hashlib import md5, sha1
except ImportError:
from md5 import md5
from sha import sha as sha1
import sha as sha1
import hmac

from Utils import *
Expand Down
4 changes: 2 additions & 2 deletions s3cmd
Expand Up @@ -768,14 +768,14 @@ def cmd_sync_local2remote(src, dst):
except KeyError:
attr = "uid"
val = st.st_uid
warning(u"%s: Owner username not known. Storing UID=%d instead." % (src, val))
warning(u"%s: Owner username not known. Storing UID=%d instead." % (unicodise(src), val))
elif attr == 'gname':
try:
val = grp.getgrgid(st.st_gid).gr_name
except KeyError:
attr = "gid"
val = st.st_gid
warning(u"%s: Owner groupname not known. Storing GID=%d instead." % (src, val))
warning(u"%s: Owner groupname not known. Storing GID=%d instead." % (unicodise(src), val))
else:
val = getattr(st, 'st_' + attr)
attrs[attr] = val
Expand Down

0 comments on commit 6fa688f

Please sign in to comment.