Remove default port API
[deliverable/babeltrace.git] / plugins / ctf / fs / fs.c
index e734a1e1fde604187e2c49ebfa84911b31a35334..2abd9b57cc02aa77e17a3653a9afeab08ed02dcb 100644 (file)
@@ -189,12 +189,6 @@ int create_one_port(struct ctf_fs_component *ctf_fs,
                port_name->str, stream_path);
 
        /* Create output port for this file */
-       port = bt_private_component_source_add_output_private_port(
-               ctf_fs->priv_comp, port_name->str);
-       if (!port) {
-               goto error;
-       }
-
        port_data = g_new0(struct ctf_fs_port_data, 1);
        if (!port_data) {
                goto error;
@@ -205,8 +199,9 @@ int create_one_port(struct ctf_fs_component *ctf_fs,
                goto error;
        }
 
-       ret = bt_private_port_set_user_data(port, port_data);
-       if (ret) {
+       port = bt_private_component_source_add_output_private_port(
+               ctf_fs->priv_comp, port_name->str, port_data);
+       if (!port) {
                goto error;
        }
 
@@ -234,17 +229,8 @@ int create_ports(struct ctf_fs_component *ctf_fs)
        const char *basename;
        GError *error = NULL;
        GDir *dir = NULL;
-       struct bt_private_port *def_port;
        struct ctf_fs_file *file = NULL;
 
-       /* Remove default port if needed */
-       def_port = bt_private_component_source_get_default_output_private_port(
-               ctf_fs->priv_comp);
-       if (def_port) {
-               bt_private_port_remove_from_component(def_port);
-               bt_put(def_port);
-       }
-
        /* Create one output port for each stream file */
        dir = g_dir_open(ctf_fs->trace_path->str, 0, &error);
        if (!dir) {
This page took 0.026577 seconds and 5 git commands to generate.