mirror of
https://github.com/slsdetectorgroup/slsDetectorPackage.git
synced 2025-06-18 15:57:13 +02:00
esrf changes: eiver: initialise global optind variable before calling getopt_long: Needed when multiple receivers are instantiated in the same process
This commit is contained in:
@ -50,14 +50,8 @@ private:
|
|||||||
unsigned int tail; // input index
|
unsigned int tail; // input index
|
||||||
unsigned int head; // output index
|
unsigned int head; // output index
|
||||||
unsigned int Capacity;
|
unsigned int Capacity;
|
||||||
//#ifdef __cplusplus >= 201103L
|
|
||||||
mutable sem_t data_mutex;
|
mutable sem_t data_mutex;
|
||||||
mutable sem_t free_mutex;
|
mutable sem_t free_mutex;
|
||||||
//#else
|
|
||||||
// sem_t free_mutex;
|
|
||||||
|
|
||||||
//#endif
|
|
||||||
|
|
||||||
unsigned int increment(unsigned int idx_) const;
|
unsigned int increment(unsigned int idx_) const;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -42,7 +42,8 @@ slsReceiver::slsReceiver(int argc, char *argv[], int &success):
|
|||||||
{0, 0, 0, 0}
|
{0, 0, 0, 0}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
//initialize global optind variable (required when instantiating multiple receivers in the same process)
|
||||||
|
optind = 1;
|
||||||
// getopt_long stores the option index here.
|
// getopt_long stores the option index here.
|
||||||
int option_index = 0;
|
int option_index = 0;
|
||||||
int c = 0;
|
int c = 0;
|
||||||
|
Reference in New Issue
Block a user