diff options
author | Campbell Barton <ideasman42@gmail.com> | 2011-04-05 02:42:43 +0400 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2011-04-05 02:42:43 +0400 |
commit | 162d02bf5014bd881a1268aca156009108159ff4 (patch) | |
tree | 65889d11336f8c9bb37fdae936b95628af235af8 /source | |
parent | b3bc0040d8ee88696d14aae9b59673d5f1bc83c1 (diff) |
quiet warning & minor pep8 edits.
Diffstat (limited to 'source')
-rw-r--r-- | source/blender/blenkernel/intern/pointcache.c | 2 | ||||
-rw-r--r-- | source/tests/bl_test.py | 4 |
2 files changed, 4 insertions, 2 deletions
diff --git a/source/blender/blenkernel/intern/pointcache.c b/source/blender/blenkernel/intern/pointcache.c index 587d1dc01a2..a8447e2a12a 100644 --- a/source/blender/blenkernel/intern/pointcache.c +++ b/source/blender/blenkernel/intern/pointcache.c @@ -1028,7 +1028,6 @@ static int ptcache_file_compressed_read(PTCacheFile *pf, unsigned char *result, size_t in_len; #ifdef WITH_LZO size_t out_len = len; - size_t sizeOfIt = 5; #endif unsigned char *in; unsigned char *props = MEM_callocN(16*sizeof(char), "tmp"); @@ -1051,6 +1050,7 @@ static int ptcache_file_compressed_read(PTCacheFile *pf, unsigned char *result, #ifdef WITH_LZMA if(compressed == 2) { + size_t sizeOfIt; size_t leni = in_len, leno = out_len; ptcache_file_read(pf, &size, 1, sizeof(unsigned int)); sizeOfIt = (size_t)size; diff --git a/source/tests/bl_test.py b/source/tests/bl_test.py index 5dd7dbe32d7..cfe91356444 100644 --- a/source/tests/bl_test.py +++ b/source/tests/bl_test.py @@ -170,7 +170,9 @@ def main(): md5_update = md5_instance.update for f in md5_source: - md5_update(open(f, "rb").read()) + filehandle = open(f, "rb") + md5_update(filehandle.read()) + filehandle.close() md5_new = md5_instance.hexdigest() |