diff --git a/picohttp/democlient.h b/picohttp/democlient.h index 1c88100f8..75c24a5a4 100644 --- a/picohttp/democlient.h +++ b/picohttp/democlient.h @@ -61,9 +61,9 @@ typedef struct st_picoquic_demo_stream_ctx_t { uint64_t post_sent; char* f_name; FILE* F; /* NULL if stream is closed or no_disk. */ - int is_open : 1; - int is_file_open : 1; - int flow_opened : 1; + unsigned int is_open : 1; + unsigned int is_file_open : 1; + unsigned int flow_opened : 1; } picoquic_demo_client_stream_ctx_t; typedef struct st_picoquic_demo_client_callback_ctx_t { diff --git a/picoquic/frames.c b/picoquic/frames.c index f976e8f3f..2c0947998 100644 --- a/picoquic/frames.c +++ b/picoquic/frames.c @@ -2041,7 +2041,6 @@ uint8_t* picoquic_copy_single_stream_frame_for_retransmit(picoquic_cnx_t* cnx, p uint8_t* picoquic_copy_stream_frames_for_retransmit(picoquic_cnx_t* cnx, uint8_t* bytes_next, uint8_t* bytes_max, uint64_t current_priority, int* more_data, int* is_pure_ack) { - uint8_t* bytes_first; int more_retransmit = 0; int packet_dequeued = 0; picoquic_packet_t* packet = NULL; @@ -2055,7 +2054,6 @@ uint8_t* picoquic_copy_stream_frames_for_retransmit(picoquic_cnx_t* cnx, break; } else { - bytes_first = bytes_next; more_retransmit = 0; bytes_next = picoquic_copy_single_stream_frame_for_retransmit(cnx, packet, bytes_next, bytes_max, current_priority, &more_retransmit, &packet_dequeued, is_pure_ack); diff --git a/picoquictest/mediatest.c b/picoquictest/mediatest.c index 04724ce38..e80a26c98 100644 --- a/picoquictest/mediatest.c +++ b/picoquictest/mediatest.c @@ -1111,8 +1111,6 @@ int mediatest_loop(mediatest_ctx_t* mt_ctx, uint64_t simulated_time_max, int is_ int mediatest_one(int media_test_id, mediatest_spec_t * spec) { int ret = 0; - int nb_steps = 0; - int nb_inactive = 0; int is_finished = 0; /* set the configuration */ diff --git a/picoquictest/minicrypto_test.c b/picoquictest/minicrypto_test.c index 34955a3ac..6821ec02c 100644 --- a/picoquictest/minicrypto_test.c +++ b/picoquictest/minicrypto_test.c @@ -112,11 +112,11 @@ int minicrypto_is_last_test() int expected_aes128gcm_sha256 = 1; int expected_aes128gcm_sha256_low = 1; int expected_set_key = 1; - int actual_aes128gcm_sha256; - int actual_aes128gcm_sha256_low; + int using_aes128gcm_sha256; + int using_aes128gcm_sha256_low; int actual_set_key; - void* actual_aes128gcmsha256 = picoquic_get_aes128gcm_sha256_v(0); - void* actual_aes128gcmsha256_low = picoquic_get_aes128gcm_sha256_v(1); + void* actual_aes128gcm_sha256 = picoquic_get_aes128gcm_sha256_v(0); + void* actual_aes128gcm_sha256_low = picoquic_get_aes128gcm_sha256_v(1); picoquic_tls_api_reset(0); @@ -129,25 +129,19 @@ int minicrypto_is_last_test() #if !defined(PTLS_WITHOUT_OPENSSL) expected_set_key = 0; #endif - actual_aes128gcm_sha256 = (actual_aes128gcmsha256 == (void*)&ptls_minicrypto_aes128gcmsha256); - actual_aes128gcm_sha256_low = (actual_aes128gcmsha256 == (void*)&ptls_minicrypto_aes128gcmsha256); + using_aes128gcm_sha256 = (actual_aes128gcm_sha256 == (void*)&ptls_minicrypto_aes128gcmsha256); + using_aes128gcm_sha256_low = (actual_aes128gcm_sha256_low == (void*)&ptls_minicrypto_aes128gcmsha256); actual_set_key = (picoquic_set_private_key_from_file_fn == picoquic_minicrypto_set_key_fn); - if (actual_aes128gcm_sha256 != expected_aes128gcm_sha256) { + if (using_aes128gcm_sha256 != expected_aes128gcm_sha256) { DBG_PRINTF("Wrong aes gcm 128 sha 256. Expected: %s, actual: %s", (expected_aes128gcm_sha256) ? "minicrypto" : "other", - (actual_aes128gcm_sha256) ? "minicrypto" : "other"); + (using_aes128gcm_sha256) ? "minicrypto" : "other"); ret = -1; } - if (actual_aes128gcm_sha256 != expected_aes128gcm_sha256) { - DBG_PRINTF("Wrong aes gcm 128 sha 256. Expected: %s, actual: %s", - (expected_aes128gcm_sha256) ? "minicrypto" : "other", - (actual_aes128gcm_sha256) ? "minicrypto" : "other"); - ret = -1; - } - if (actual_aes128gcm_sha256 != expected_aes128gcm_sha256) { - DBG_PRINTF("Wrong aes gcm 128 sha 256. Expected: %s, actual: %s", - (expected_aes128gcm_sha256) ? "minicrypto" : "other", - (actual_aes128gcm_sha256) ? "minicrypto" : "other"); + if (using_aes128gcm_sha256_low != expected_aes128gcm_sha256_low) { + DBG_PRINTF("Wrong aes gcm 128 sha 256 low. Expected: %s, actual: %s", + (expected_aes128gcm_sha256_low) ? "minicrypto" : "other", + (using_aes128gcm_sha256_low) ? "minicrypto" : "other"); ret = -1; } if (actual_set_key != expected_set_key) {