Fix compile error with clang-6.0
@@ -54,13 +54,13 @@ int main() {
/* initialize the CUnit test registry */
if (CUE_SUCCESS != CU_initialize_registry())
- return CU_get_error();
+ return (int)CU_get_error();
/* add a suite to the registry */
pSuite = CU_add_suite("libngtcp2_TestSuite", init_suite1, clean_suite1);
if (NULL == pSuite) {
CU_cleanup_registry();
- return CU_get_error();
+ return (int)CU_get_error();
}
/* add the tests to the suite */
@@ -203,7 +203,7 @@ int main() {
!CU_add_test(pSuite, "conn_pkt_payloadlen",
test_ngtcp2_conn_pkt_payloadlen)) {
CU_cleanup_registry();
- return CU_get_error();
+ return (int)CU_get_error();
}
/* Run all tests using the CUnit Basic interface */
@@ -215,6 +215,6 @@ int main() {
return (int)num_tests_failed;
} else {
printf("CUnit Error: %s\n", CU_get_error_msg());
- return CU_get_error();
+ return (int)CU_get_error();
}
}
