mirror of
https://github.com/love2d/love.git
synced 2026-08-12 16:40:57 +02:00
Ehm, unsigned double.. sure..
This commit is contained in:
@@ -64,7 +64,7 @@ namespace sound
|
||||
SoundData::SoundData(int samples, int sampleRate, int bits, int channels)
|
||||
: data(0), size(samples*(bits/8)*channels), sampleRate(sampleRate), bits(bits), channels(channels)
|
||||
{
|
||||
unsigned double realsize = samples;
|
||||
double realsize = samples;
|
||||
realsize *= (bits/8)*channels;
|
||||
if (realsize > INT_MAX)
|
||||
throw love::Exception("Data is too big!");
|
||||
@@ -76,7 +76,7 @@ namespace sound
|
||||
SoundData::SoundData(void * d, int samples, int sampleRate, int bits, int channels)
|
||||
: data(0), size(samples*(bits/8)*channels), sampleRate(sampleRate), bits(bits), channels(channels)
|
||||
{
|
||||
unsigned double realsize = samples;
|
||||
double realsize = samples;
|
||||
realsize *= (bits/8)*channels;
|
||||
if (realsize > INT_MAX)
|
||||
throw love::Exception("Data is too big!");
|
||||
|
||||
Reference in New Issue
Block a user