Merge of new user interface changes
This commit is contained in:
@ -73,7 +73,7 @@ MONITOR *mon;
|
|||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
mon->handle = (*mon->module->startMonitor)(NULL);
|
mon->handle = (*mon->module->startMonitor)(NULL);
|
||||||
mon->state |= MONITOR_RUNNING;
|
mon->state |= MONITOR_STATE_RUNNING;
|
||||||
spinlock_acquire(&monLock);
|
spinlock_acquire(&monLock);
|
||||||
mon->next = allMonitors;
|
mon->next = allMonitors;
|
||||||
allMonitors = mon;
|
allMonitors = mon;
|
||||||
@ -94,7 +94,7 @@ monitor_free(MONITOR *mon)
|
|||||||
MONITOR *ptr;
|
MONITOR *ptr;
|
||||||
|
|
||||||
mon->module->stopMonitor(mon->handle);
|
mon->module->stopMonitor(mon->handle);
|
||||||
mon->state &= ~MONITOR_RUNNING;
|
mon->state &= ~MONITOR_STATE_RUNNING;
|
||||||
spinlock_acquire(&monLock);
|
spinlock_acquire(&monLock);
|
||||||
if (allMonitors == mon)
|
if (allMonitors == mon)
|
||||||
allMonitors = mon->next;
|
allMonitors = mon->next;
|
||||||
@ -121,7 +121,7 @@ void
|
|||||||
monitorStart(MONITOR *monitor)
|
monitorStart(MONITOR *monitor)
|
||||||
{
|
{
|
||||||
monitor->handle = (*monitor->module->startMonitor)(monitor->handle);
|
monitor->handle = (*monitor->module->startMonitor)(monitor->handle);
|
||||||
monitor->state |= MONITOR_RUNNING;
|
monitor->state |= MONITOR_STATE_RUNNING;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -133,7 +133,7 @@ void
|
|||||||
monitorStop(MONITOR *monitor)
|
monitorStop(MONITOR *monitor)
|
||||||
{
|
{
|
||||||
monitor->module->stopMonitor(monitor->handle);
|
monitor->module->stopMonitor(monitor->handle);
|
||||||
monitor->state &= ~MONITOR_RUNNING;
|
monitor->state &= ~MONITOR_STATE_RUNNING;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -237,7 +237,8 @@ MONITOR *ptr;
|
|||||||
while (ptr)
|
while (ptr)
|
||||||
{
|
{
|
||||||
dcb_printf(dcb, "| %-20s | %s\n", ptr->name,
|
dcb_printf(dcb, "| %-20s | %s\n", ptr->name,
|
||||||
ptr->state & MONITOR_RUNNING ? "Running" : "Stopped");
|
ptr->state & MONITOR_STATE_RUNNING
|
||||||
|
? "Running" : "Stopped");
|
||||||
ptr = ptr->next;
|
ptr = ptr->next;
|
||||||
}
|
}
|
||||||
dcb_printf(dcb, "+----------------------+---------------------\n");
|
dcb_printf(dcb, "+----------------------+---------------------\n");
|
||||||
|
@ -81,7 +81,7 @@ typedef struct {
|
|||||||
/**
|
/**
|
||||||
* Monitor state bit mask values
|
* Monitor state bit mask values
|
||||||
*/
|
*/
|
||||||
#define MONITOR_RUNNING 0x0001
|
#define MONITOR_STATE_RUNNING 0x0001
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
Reference in New Issue
Block a user