Skip to content

Commit

Permalink
Ignore warning due to not checking writev
Browse files Browse the repository at this point in the history
Cannot really do anything useful anyway...
  • Loading branch information
cyrus-and committed Oct 2, 2023
1 parent ae0cc8e commit fdf0e8c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions ext/fracker.patch
Original file line number Diff line number Diff line change
Expand Up @@ -104,14 +104,14 @@ new file mode 100644
+{
+ struct iovec to_write[2];
+
+ /* TODO properly check the writev syscall */
+ /* TODO properly check the writev syscall (XXX warning is suppressed) */
+
+ /* write the object followed by a newline then cleanup */
+ to_write[0].iov_base = (void *)json_object_to_json_string(object);
+ to_write[0].iov_len = strlen(to_write[0].iov_base);
+ to_write[1].iov_base = "\n";
+ to_write[1].iov_len = 1;
+ writev(fd, to_write, 2);
+ (void)!writev(fd, to_write, 2);
+ json_object_put(object);
+}
+
Expand Down

0 comments on commit fdf0e8c

Please sign in to comment.