submaster always conflates

This commit is contained in:
Willem Melching 2020-05-21 15:06:50 -07:00
parent 30838d40a4
commit 4bb1eb826d
2 changed files with 3 additions and 4 deletions

View File

@ -61,7 +61,7 @@ public:
class SubMaster {
public:
SubMaster(const std::initializer_list<const char *> &service_list,
const char *address = nullptr, bool conflate = false, const std::initializer_list<const char *> &ignore_alive = {});
const char *address = nullptr, const std::initializer_list<const char *> &ignore_alive = {});
int update(int timeout = 1000);
inline bool allAlive(const std::initializer_list<const char *> &service_list = {}) { return all_(service_list, false, true); }
inline bool allValid(const std::initializer_list<const char *> &service_list = {}) { return all_(service_list, true, false); }
@ -90,4 +90,3 @@ class PubMaster {
private:
std::map<std::string, PubSocket *> sockets_;
};

View File

@ -44,12 +44,12 @@ struct SubMaster::SubMessage {
};
SubMaster::SubMaster(const std::initializer_list<const char *> &service_list, const char *address,
bool conflate, const std::initializer_list<const char *> &ignore_alive) {
const std::initializer_list<const char *> &ignore_alive) {
poller_ = Poller::create();
for (auto name : service_list) {
const service *serv = get_service(name);
assert(serv != nullptr);
SubSocket *socket = SubSocket::create(ctx.ctx_, name, address ? address : "127.0.0.1", conflate);
SubSocket *socket = SubSocket::create(ctx.ctx_, name, address ? address : "127.0.0.1", true);
assert(socket != 0);
poller_->registerSocket(socket);
SubMessage *m = new SubMessage{