projects
/
lttng-tools.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Fix: consumerd: consumed size miscomputed during statistics sampling
[lttng-tools.git]
/
tests
/
regression
/
tools
/
trigger
/
utils
/
notification-client.cpp
diff --git
a/tests/regression/tools/trigger/utils/notification-client.cpp
b/tests/regression/tools/trigger/utils/notification-client.cpp
index 02dc0626087aa6ff77ac065b8de482b03674a1f8..27bd100c694fbd567e8a5b6e055b317f583b3c53 100644
(file)
--- a/
tests/regression/tools/trigger/utils/notification-client.cpp
+++ b/
tests/regression/tools/trigger/utils/notification-client.cpp
@@
-7,6
+7,8
@@
#include "utils.h"
#include "utils.h"
+#include <common/error.hpp>
+
#include <lttng/action/list-internal.hpp>
#include <lttng/condition/event-rule-matches.h>
#include <lttng/lttng.h>
#include <lttng/action/list-internal.hpp>
#include <lttng/condition/event-rule-matches.h>
#include <lttng/lttng.h>
@@
-38,13
+40,12
@@
static struct option long_options[] = {
static bool action_list_contains_notify(const struct lttng_action *action_list)
{
static bool action_list_contains_notify(const struct lttng_action *action_list)
{
- const struct lttng_action *sub_action;
-
- for_each_action_const (sub_action, action_list) {
+ for (auto sub_action : lttng::ctl::const_action_list_view(action_list)) {
if (lttng_action_get_type(sub_action) == LTTNG_ACTION_TYPE_NOTIFY) {
return true;
}
}
if (lttng_action_get_type(sub_action) == LTTNG_ACTION_TYPE_NOTIFY) {
return true;
}
}
+
return false;
}
return false;
}
@@
-82,7
+83,7
@@
end:
return names_match;
}
return names_match;
}
-
int
main(int argc, char **argv)
+
static int _
main(int argc, char **argv)
{
int ret;
int option;
{
int ret;
int option;
@@
-280,3
+281,13
@@
end:
free(expected_trigger_name);
return !!ret;
}
free(expected_trigger_name);
return !!ret;
}
+
+int main(int argc, char **argv)
+{
+ try {
+ return _main(argc, argv);
+ } catch (const std::exception& e) {
+ ERR_FMT("Unhandled exception caught by notification client: {}", e.what());
+ abort();
+ }
+}
This page took
0.024055 seconds
and
4
git commands to generate.