no run-time dyn memory allocation now
This commit is contained in:
@ -68,12 +68,15 @@ int ServiceInterfaceBuffer::overflow(int c) {
|
||||
}
|
||||
|
||||
int ServiceInterfaceBuffer::sync(void) {
|
||||
if(not this->isActive) {
|
||||
if(not this->isActive and not buffered) {
|
||||
if(not buffered) {
|
||||
setp(buf, buf + BUF_SIZE - 1);
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
if(not buffered) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
size_t preambleSize = 0;
|
||||
auto preamble = getPreamble(&preambleSize);
|
||||
@ -88,6 +91,9 @@ int ServiceInterfaceBuffer::sync(void) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
bool ServiceInterfaceBuffer::isBuffered() const {
|
||||
return buffered;
|
||||
}
|
||||
|
||||
std::string ServiceInterfaceBuffer::getPreamble(size_t * preambleSize) {
|
||||
Clock::TimeOfDay_t loggerTime;
|
||||
|
Reference in New Issue
Block a user