libndr: Use GUID_compare in GUID_equal
authorVolker Lendecke <vl@samba.org>
Thu, 5 Jun 2014 09:56:55 +0000 (09:56 +0000)
committerJeremy Allison <jra@samba.org>
Tue, 10 Jun 2014 17:19:13 +0000 (19:19 +0200)
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
librpc/ndr/uuid.c

index cefe7b65d4f386c8e7422fbf7cf621ae3b62f538..5558cb6be9d8da7a7081705d5c7c5a93840479d1 100644 (file)
@@ -197,15 +197,7 @@ _PUBLIC_ bool GUID_all_zero(const struct GUID *u)
 
 _PUBLIC_ bool GUID_equal(const struct GUID *u1, const struct GUID *u2)
 {
-       if (u1->time_low != u2->time_low ||
-           u1->time_mid != u2->time_mid ||
-           u1->time_hi_and_version != u2->time_hi_and_version ||
-           u1->clock_seq[0] != u2->clock_seq[0] ||
-           u1->clock_seq[1] != u2->clock_seq[1] ||
-           memcmp(u1->node, u2->node, 6) != 0) {
-               return false;
-       }
-       return true;
+       return (GUID_compare(u1, u2) == 0);
 }
 
 _PUBLIC_ int GUID_compare(const struct GUID *u1, const struct GUID *u2)