You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
26 lines
437 B
26 lines
437 B
2 months ago
|
|
||
|
#include <sys/resource.h>
|
||
|
|
||
|
#include "common/ratekeeper.h"
|
||
|
#include "common/util.h"
|
||
|
#include "system/proclogd/proclog.h"
|
||
|
|
||
|
ExitHandler do_exit;
|
||
|
|
||
|
int main(int argc, char **argv) {
|
||
|
setpriority(PRIO_PROCESS, 0, -15);
|
||
|
|
||
|
RateKeeper rk("proclogd", 0.5);
|
||
|
PubMaster publisher({"procLog"});
|
||
|
|
||
|
while (!do_exit) {
|
||
|
MessageBuilder msg;
|
||
|
buildProcLogMessage(msg);
|
||
|
publisher.send("procLog", msg);
|
||
|
|
||
|
rk.keepTime();
|
||
|
}
|
||
|
|
||
|
return 0;
|
||
|
}
|