struct OnstartFlags {
bool rw_ready : 1;
+ bool log_ready : 1;
// Not actually "onstart" commands:
bool no_sigterm : 1; // do not send SIGTERM
bool runs_on_console : 1; // run "in the foreground"
- OnstartFlags() noexcept : rw_ready(false),
+ OnstartFlags() noexcept : rw_ready(false), log_ready(false),
no_sigterm(false), runs_on_console(false)
{
}
public:
// TODO resolve clunkiness of storing this field
ServiceRecord * service;
- void gotTermStat(EventLoop_t * eloop, pid_t child, int status) noexcept;
+ Rearm childStatus(EventLoop_t &eloop, pid_t child, int status) noexcept;
ServiceChildWatcher(ServiceRecord * sr) noexcept : service(sr) { }
};
// TODO resolve clunkiness of storing these fields
int fd;
ServiceRecord * service;
- Rearm gotEvent(EventLoop_t * eloop, int fd, int flags) noexcept;
+ Rearm fdEvent(EventLoop_t &eloop, int fd, int flags) noexcept;
ServiceIoWatcher(ServiceRecord * sr) noexcept : service(sr) { }
- void registerWith(EventLoop_t *loop, int fd, int flags)
+ void addWatch(EventLoop_t &loop, int fd, int flags)
{
this->fd = fd;
- EventLoop_t::FdWatcher::registerWith(loop, fd, flags);
+ EventLoop_t::FdWatcher::addWatch(loop, fd, flags);
}
};
{
auto prev_tail = console_queue_tail;
console_queue_tail = newTail;
+ newTail->next_for_console = nullptr;
if (! prev_tail) {
console_queue_head = newTail;
enable_console_log(false);