Standardize `!ptr` i/o `ptr == NULL`, `ptr` i/o `ptr != NULL`
[babeltrace.git] / src / ctf-writer / stream.c
index 7d371ffd97a234781331191b318068857b572cc2..3f5e610094e7c45ef311070ca91032274d89c13a 100644 (file)
 #include <stdint.h>
 #include <unistd.h>
 
-#include <babeltrace2/ctf-writer/field-types.h>
-#include <babeltrace2/ctf-writer/object.h>
-#include <babeltrace2/ctf-writer/stream-class.h>
-#include <babeltrace2/ctf-writer/stream.h>
-#include <babeltrace2/ctf-writer/trace.h>
+#include <babeltrace2-ctf-writer/field-types.h>
+#include <babeltrace2-ctf-writer/object.h>
+#include <babeltrace2-ctf-writer/stream-class.h>
+#include <babeltrace2-ctf-writer/stream.h>
+#include <babeltrace2-ctf-writer/trace.h>
 
 #include "common/align.h"
 #include "common/assert.h"
@@ -1021,7 +1021,7 @@ append_ids:
                stream_class_id, stream->common.id);
 
        file_path = g_build_filename(writer->path->str, filename->str, NULL);
-       if (file_path == NULL) {
+       if (!file_path) {
                ret = -1;
                goto end;
        }
@@ -1627,7 +1627,7 @@ int bt_ctf_stream_flush(struct bt_ctf_stream *stream)
 
                packet_size_field = bt_ctf_field_structure_get_field_by_name(
                                stream->packet_context, "packet_size");
-               has_packet_size = (packet_size_field != NULL);
+               has_packet_size = packet_size_field;
                bt_ctf_object_put_ref(packet_size_field);
        }
 
This page took 0.023091 seconds and 4 git commands to generate.