Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
path: root/common/Util/Clooper/audio.cpp
diff options
context:
space:
mode:
authorNat <natcl@hotmail.com>2007-11-08 17:42:19 (GMT)
committer Nat <natcl@hotmail.com>2007-11-08 17:42:19 (GMT)
commit0b56a247f1cc4e40523d443f52eb0a224a492bea (patch)
treee9e97fd85d05ff17706ce8b6d3b49b5b71a89c7c /common/Util/Clooper/audio.cpp
parent6b5c9dad4edcee567abb83ef98593a54c82a4633 (diff)
aclient fix by James
Diffstat (limited to 'common/Util/Clooper/audio.cpp')
-rw-r--r--common/Util/Clooper/audio.cpp12
1 files changed, 9 insertions, 3 deletions
diff --git a/common/Util/Clooper/audio.cpp b/common/Util/Clooper/audio.cpp
index 343bc99..fea9c73 100644
--- a/common/Util/Clooper/audio.cpp
+++ b/common/Util/Clooper/audio.cpp
@@ -119,8 +119,10 @@ struct SystemStuff
snd_pcm_hw_params_get_period_size_max(hw, &maxb,&maxd);
ll->printf(2, "FYI: period size range is [%li/%i,%li/%i]\n", minb,mind, maxb, maxd);
- assert(mind == 0); //rate_resample 0 makes this true right?
- assert(maxd == 0); //rate_resample 0 makes this true right?
+ if ((mind != 0) || (maxd == 0))
+ {
+ ll->printf(2, "watch out, mind and maxd non-zero... you didn't set rate_resample to 0 did you...\n");
+ }
if (period0 < minb)
{
@@ -196,7 +198,11 @@ open_error:
err = snd_pcm_writei (phandle, frame_data, frame_count );
if (err == (signed)frame_count) return 0; //success
- assert(err < 0);
+ if (err >= 0)
+ {
+ ll->printf(0, "madness on line %s:%i\n", __FILE__, __LINE__);
+ return -1;
+ }
const char * msg = NULL;
snd_pcm_state_t state = snd_pcm_state(phandle);