diff options
author | Tej Singh <singhtejinder@google.com> | 2020-07-31 23:49:39 -0700 |
---|---|---|
committer | Tej Singh <singhtejinder@google.com> | 2020-08-10 20:09:56 -0700 |
commit | 9605822dd9cb95f0761ec30beb2b1792ced5c009 (patch) | |
tree | 54a3b9d2c180f585c2e9217767779ca1ab5218e8 /cmds/statsd/src/shell/ShellSubscriber.cpp | |
parent | 906a2e4fb2d03d8296c6e8219334759193724da4 (diff) |
Partial Config Update: Matchers
There are two primary steps:
1. Determine which matchers to update
2. Perform the update
Added unit tests
Test: atest statsd_test
Bug: 162322018
Change-Id: I6dbaeb781eef362e2d024a560904497a3525cad2
Diffstat (limited to 'cmds/statsd/src/shell/ShellSubscriber.cpp')
-rw-r--r-- | cmds/statsd/src/shell/ShellSubscriber.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/cmds/statsd/src/shell/ShellSubscriber.cpp b/cmds/statsd/src/shell/ShellSubscriber.cpp index fd883c29dba0..9d8f0c24e253 100644 --- a/cmds/statsd/src/shell/ShellSubscriber.cpp +++ b/cmds/statsd/src/shell/ShellSubscriber.cpp @@ -191,7 +191,7 @@ void ShellSubscriber::writePulledAtomsLocked(const vector<std::shared_ptr<LogEve mProto.clear(); int count = 0; for (const auto& event : data) { - if (matchesSimple(*mUidMap, matcher, *event)) { + if (matchesSimple(mUidMap, matcher, *event)) { count++; uint64_t atomToken = mProto.start(util::FIELD_TYPE_MESSAGE | util::FIELD_COUNT_REPEATED | FIELD_ID_ATOM); @@ -209,7 +209,7 @@ void ShellSubscriber::onLogEvent(const LogEvent& event) { mProto.clear(); for (const auto& matcher : mSubscriptionInfo->mPushedMatchers) { - if (matchesSimple(*mUidMap, matcher, event)) { + if (matchesSimple(mUidMap, matcher, event)) { uint64_t atomToken = mProto.start(util::FIELD_TYPE_MESSAGE | util::FIELD_COUNT_REPEATED | FIELD_ID_ATOM); event.ToProto(mProto); |