projects
/
babeltrace.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
lib: rename include dir to babeltrace2
[babeltrace.git]
/
plugins
/
text
/
pretty
/
pretty.c
diff --git
a/plugins/text/pretty/pretty.c
b/plugins/text/pretty/pretty.c
index d83b30c160123b85b3693a4bfab665e90118eaff..7c548391ab79e4cecf8d33a0fccd47715b011cf6 100644
(file)
--- a/
plugins/text/pretty/pretty.c
+++ b/
plugins/text/pretty/pretty.c
@@
-23,14
+23,17
@@
* SOFTWARE.
*/
* SOFTWARE.
*/
-#include <babeltrace/babeltrace.h>
-#include <babeltrace/compiler-internal.h>
-#include <babeltrace/common-internal.h>
+#define BT_LOG_TAG "PLUGIN-TEXT-PRETTY-SINK"
+#include "logging.h"
+
+#include <babeltrace2/babeltrace.h>
+#include <babeltrace2/compiler-internal.h>
+#include <babeltrace2/common-internal.h>
#include <plugins-common.h>
#include <stdio.h>
#include <stdbool.h>
#include <glib.h>
#include <plugins-common.h>
#include <stdio.h>
#include <stdbool.h>
#include <glib.h>
-#include <babeltrace/assert-internal.h>
+#include <babeltrace
2
/assert-internal.h>
#include "pretty.h"
#include "pretty.h"
@@
-62,6
+65,9
@@
const char *plugin_options[] = {
"field-callsite",
};
"field-callsite",
};
+static
+const char * const in_port_name = "in";
+
static
void destroy_pretty_data(struct pretty_component *pretty)
{
static
void destroy_pretty_data(struct pretty_component *pretty)
{
@@
-135,8
+141,8
@@
bt_self_component_status handle_message(
ret = BT_SELF_COMPONENT_STATUS_ERROR;
}
break;
ret = BT_SELF_COMPONENT_STATUS_ERROR;
}
break;
- case BT_MESSAGE_TYPE_INACTIVITY:
-
fprintf(stderr, "Inactivity message\n
");
+ case BT_MESSAGE_TYPE_
MESSAGE_ITERATOR_
INACTIVITY:
+
BT_LOGD_STR("Message iterator inactivity message.
");
break;
case BT_MESSAGE_TYPE_DISCARDED_EVENTS:
case BT_MESSAGE_TYPE_DISCARDED_PACKETS:
break;
case BT_MESSAGE_TYPE_DISCARDED_EVENTS:
case BT_MESSAGE_TYPE_DISCARDED_PACKETS:
@@
-152,10
+158,8
@@
bt_self_component_status handle_message(
}
BT_HIDDEN
}
BT_HIDDEN
-bt_self_component_status pretty_port_connected(
- bt_self_component_sink *comp,
- bt_self_component_port_input *self_port,
- const bt_port_output *other_port)
+bt_self_component_status pretty_graph_is_configured(
+ bt_self_component_sink *comp)
{
bt_self_component_status status = BT_SELF_COMPONENT_STATUS_OK;
struct pretty_component *pretty;
{
bt_self_component_status status = BT_SELF_COMPONENT_STATUS_OK;
struct pretty_component *pretty;
@@
-165,7
+169,8
@@
bt_self_component_status pretty_port_connected(
BT_ASSERT(pretty);
BT_ASSERT(!pretty->iterator);
pretty->iterator = bt_self_component_port_input_message_iterator_create(
BT_ASSERT(pretty);
BT_ASSERT(!pretty->iterator);
pretty->iterator = bt_self_component_port_input_message_iterator_create(
- self_port);
+ bt_self_component_sink_borrow_input_port_by_name(comp,
+ in_port_name));
if (!pretty->iterator) {
status = BT_SELF_COMPONENT_STATUS_NOMEM;
}
if (!pretty->iterator) {
status = BT_SELF_COMPONENT_STATUS_NOMEM;
}
@@
-650,7
+655,8
@@
bt_self_component_status pretty_init(
goto end;
}
goto end;
}
- ret = bt_self_component_sink_add_input_port(comp, "in", NULL, NULL);
+ ret = bt_self_component_sink_add_input_port(comp, in_port_name,
+ NULL, NULL);
if (ret != BT_SELF_COMPONENT_STATUS_OK) {
goto end;
}
if (ret != BT_SELF_COMPONENT_STATUS_OK) {
goto end;
}
This page took
0.024128 seconds
and
4
git commands to generate.