eDebug("eFilePushThread *write error* - not yet handled");
// ... we would stop the thread
}
- printf("FILEPUSH: wrote %d bytes\n", w);
+// printf("FILEPUSH: wrote %d bytes\n", w);
m_buf_start += w;
continue;
}
continue;
eDebug("eFilePushThread *read error* - not yet handled");
}
- printf("FILEPUSH: read %d bytes\n", m_buf_end);
+ if (m_buf_end == 0)
+ {
+ eDebug("FILEPUSH: end-of-file! (currently unhandled)");
+ if (!lseek(m_fd_source, 0, SEEK_SET))
+ {
+ eDebug("(looping)");
+ continue;
+ }
+ break;
+ }
+// printf("FILEPUSH: read %d bytes\n", m_buf_end);
}
eDebug("FILEPUSH THREAD STOP");