platform: avoid compiler error passing NMP_OBJECT_CAST_OBJ_WITH_IFINDEX() to nm_hash_update_vals()

Clang (3.4.2-9.el7) on CentOS 7.6 fails related to nm_hash_update_vals().

Clang seems to dislike passing certain complex arguments to typeof().
I'd prefer to fix nm_hash_update_vals() to not have this problem,
but I don't know how.

This works around the issue.
This commit is contained in:
Thomas Haller 2019-05-28 15:07:34 +02:00
parent ad06cc78dc
commit 5113c5bd00

View file

@ -398,7 +398,7 @@ _idx_obj_part (const DedupMultiIdxType *idx_type,
if (h) {
nm_hash_update_vals (h,
idx_type->cache_id_type,
NMP_OBJECT_CAST_OBJ_WITH_IFINDEX (obj_a)->ifindex);
obj_a->obj_with_ifindex.ifindex);
}
return 1;