|
rllib
1
|

Go to the source code of this file.
Classes | |
| struct | WORKER_DATA |
Defines | |
| #define | CLIENT_TIMEOUT 1000 |
Functions | |
| static void * | workerThread (void *arg) |
| static void * | rlDataProviderAccept (void *arg) |
| #define CLIENT_TIMEOUT 1000 |
Definition at line 333 of file rldataprovider.cpp.
| static void* rlDataProviderAccept | ( | void * | arg | ) | [static] |
Definition at line 593 of file rldataprovider.cpp.
{
int s;
rlThread worker;
WORKER_DATA worker_data;
rlDataProviderThreads *provider_threads;
THREAD_PARAM *p = (THREAD_PARAM *) arg;
if(arg == NULL) return NULL;
provider_threads = (rlDataProviderThreads *) p->user;
if(provider_threads == NULL) return NULL;
rlSocket socket("localhost",provider_threads->port,0);
while(1)
{
s = socket.connect();
if(s == -1) break;
worker_data.thread = provider_threads;
worker_data.socket = s;
worker.create(workerThread,&worker_data);
rlsleep(100);
}
return NULL;
}
| static void* workerThread | ( | void * | arg | ) | [static] |
Definition at line 580 of file rldataprovider.cpp.
{
WORKER_DATA *worker_data;
THREAD_PARAM *p = (THREAD_PARAM *) arg;
if(arg == NULL) return NULL;
worker_data = (WORKER_DATA *) p->user;
rlSocket socket(worker_data->socket);
worker_data->thread->provider->run(&socket);
return NULL;
}
1.7.5.1