tree-wide: use sd_id128_is_null() instead of sd_id128_equal where appropriate

It's a bit easier to read because shorter. Also, most likely a tiny bit faster.
This commit is contained in:
Lennart Poettering
2016-07-22 12:38:08 +02:00
parent bf3dd08a81
commit 3bbaff3e08
8 changed files with 13 additions and 13 deletions
+1 -1
View File
@@ -1266,7 +1266,7 @@ static int add_boot(sd_journal *j) {
/* Take a shortcut and use the current boot_id, which we can do very quickly.
* We can do this only when we logs are coming from the current machine,
* so take the slow path if log location is specified. */
if (arg_boot_offset == 0 && sd_id128_equal(arg_boot_id, SD_ID128_NULL) &&
if (arg_boot_offset == 0 && sd_id128_is_null(arg_boot_id) &&
!arg_directory && !arg_file)
return add_match_this_boot(j, arg_machine);
+1 -1
View File
@@ -877,7 +877,7 @@ void server_driver_message(Server *s, sd_id128_t message_id, const char *format,
assert_cc(6 == LOG_INFO);
IOVEC_SET_STRING(iovec[n++], "PRIORITY=6");
if (!sd_id128_equal(message_id, SD_ID128_NULL)) {
if (!sd_id128_is_null(message_id)) {
snprintf(mid, sizeof(mid), LOG_MESSAGE_ID(message_id));
IOVEC_SET_STRING(iovec[n++], mid);
}