Mercurial > audlegacy
comparison audacious/output.c @ 1051:6e95edd16b43 trunk
[svn] - if writable == 0 then bail out of produce_audio() instead of segfault
author | nenolod |
---|---|
date | Sun, 14 May 2006 20:35:37 -0700 |
parents | 976a54334538 |
children | 86da433104a8 |
comparison
equal
deleted
inserted
replaced
1050:3131795a78c4 | 1051:6e95edd16b43 |
---|---|
386 int writable = length - writeoffs; | 386 int writable = length - writeoffs; |
387 | 387 |
388 if (writable > 2048) | 388 if (writable > 2048) |
389 writable = 2048; | 389 writable = 2048; |
390 | 390 |
391 if (writable == 0) | |
392 return; | |
393 | |
391 while (op->buffer_free() < writable) { /* wait output buf */ | 394 while (op->buffer_free() < writable) { /* wait output buf */ |
392 if (going && !*going) /* thread stopped? */ | 395 if (going && !*going) /* thread stopped? */ |
393 return; /* so finish */ | 396 return; /* so finish */ |
394 | 397 |
395 if (ip_data.stop) /* has a stop been requested? */ | 398 if (ip_data.stop) /* has a stop been requested? */ |