commited patch sent by John Hay, fixing FreeBSD problems

This commit is contained in:
darkeye 2004-01-07 13:18:17 +00:00
parent 7f5f2f7480
commit 7efa982a2a
2 changed files with 29 additions and 3 deletions

View File

@ -114,6 +114,7 @@ class LameLibEncoder : public AudioEncoder, public virtual Reporter
int lowpass, int lowpass,
int highpass ) throw ( Exception ) int highpass ) throw ( Exception )
{ {
this->lameGlobalFlags = NULL;
this->sink = sink; this->sink = sink;
this->lowpass = lowpass; this->lowpass = lowpass;
this->highpass = highpass; this->highpass = highpass;
@ -447,6 +448,9 @@ class LameLibEncoder : public AudioEncoder, public virtual Reporter
$Source$ $Source$
$Log$ $Log$
Revision 1.15 2004/01/07 13:18:17 darkeye
commited patch sent by John Hay, fixing FreeBSD problems
Revision 1.14 2002/08/04 10:26:06 darkeye Revision 1.14 2002/08/04 10:26:06 darkeye
added additional error checking to make sure that outChannel < inChannel added additional error checking to make sure that outChannel < inChannel

View File

@ -29,6 +29,17 @@
/* ============================================================ include files */ /* ============================================================ include files */
#ifdef HAVE_CONFIG_H
#include "config.h"
#endif
#ifdef HAVE_SYS_TYPES_H
#include <sys/types.h>
#else
#error need sys/types.h
#endif
#include "Exception.h" #include "Exception.h"
#include "MultiThreadedConnector.h" #include "MultiThreadedConnector.h"
@ -132,6 +143,7 @@ bool
MultiThreadedConnector :: open ( void ) throw ( Exception ) MultiThreadedConnector :: open ( void ) throw ( Exception )
{ {
unsigned int i; unsigned int i;
size_t st;
if ( !Connector::open() ) { if ( !Connector::open() ) {
return false; return false;
@ -140,6 +152,13 @@ MultiThreadedConnector :: open ( void ) throw ( Exception )
running = true; running = true;
pthread_attr_init( &threadAttr); pthread_attr_init( &threadAttr);
pthread_attr_getstacksize(&threadAttr, &st);
if (st < 128 * 1024) {
reportEvent( 5, "MultiThreadedConnector :: open, stack size ",
(long)st);
st = 128 * 1024;
pthread_attr_setstacksize(&threadAttr, st);
}
pthread_attr_setdetachstate( &threadAttr, PTHREAD_CREATE_JOINABLE); pthread_attr_setdetachstate( &threadAttr, PTHREAD_CREATE_JOINABLE);
threads = new ThreadData[numSinks]; threads = new ThreadData[numSinks];
@ -347,6 +366,9 @@ MultiThreadedConnector :: ThreadData :: threadFunction( void * param )
$Source$ $Source$
$Log$ $Log$
Revision 1.4 2004/01/07 13:18:17 darkeye
commited patch sent by John Hay, fixing FreeBSD problems
Revision 1.3 2002/10/20 20:43:17 darkeye Revision 1.3 2002/10/20 20:43:17 darkeye
more graceful reconnect more graceful reconnect