forked from bartvdbraak/blender
c3d_import needed encoding defined for python 2.5+ to run.
wav file reading minor fix checking array bounds.
This commit is contained in:
parent
167676dbfe
commit
2ee4feda26
@ -309,7 +309,7 @@ unsigned int SND_GetNumberOfSamples(void* sample, int sample_length)
|
||||
{
|
||||
offset += block_align;
|
||||
|
||||
if (offset+4 > sample_length) /* save us from crashing */
|
||||
if (offset+block_align > sample_length) /* save us from crashing */
|
||||
return 0;
|
||||
}
|
||||
offset += 4;
|
||||
@ -347,7 +347,7 @@ unsigned int SND_GetHeaderSize(void* sample, int sample_length)
|
||||
{
|
||||
offset += block_align;
|
||||
|
||||
if (offset+4 > sample_length) /* save us from crashing */
|
||||
if (offset+block_align > sample_length) /* save us from crashing */
|
||||
return 0;
|
||||
}
|
||||
headersize = offset + 8;
|
||||
|
@ -1,5 +1,5 @@
|
||||
#!BPY
|
||||
|
||||
# -*- coding: latin-1 -*-
|
||||
"""
|
||||
Name: 'Motion Capture (.c3d)...'
|
||||
Blender: 246
|
||||
|
Loading…
Reference in New Issue
Block a user