]> git.ipfire.org Git - thirdparty/shairport-sync.git/commitdiff
quieten a few compiler warnings
authorMike Brady <mikebrady@eircom.net>
Sun, 20 May 2018 14:12:33 +0000 (15:12 +0100)
committerMike Brady <mikebrady@eircom.net>
Sun, 20 May 2018 14:12:33 +0000 (15:12 +0100)
player.c
rtp.c

index ca24cface755c9a04e235e4dd47d47e8313cbdeb..8e51c9c30b6ef8454cf2ea14263fcc24fefc0b98 100644 (file)
--- a/player.c
+++ b/player.c
@@ -1556,7 +1556,7 @@ static void *player_thread_func(void *arg) {
   int at_least_one_frame_seen = 0;
   int64_t tsum_of_sync_errors, tsum_of_corrections, tsum_of_insertions_and_deletions,
       tsum_of_drifts;
-  int64_t previous_sync_error, previous_correction;
+  int64_t previous_sync_error = 0, previous_correction = 0;
   int64_t minimum_dac_queue_size = INT64_MAX;
   int32_t minimum_buffer_occupancy = INT32_MAX;
   int32_t maximum_buffer_occupancy = INT32_MIN;
@@ -2516,7 +2516,7 @@ void player_volume_without_notification(double airplay_volume, rtsp_conn_info *c
       }
     }
   */
-  double hardware_attenuation, software_attenuation = 0.0;
+  double hardware_attenuation = 0.0, software_attenuation = 0.0;
   double scaled_attenuation = hw_min_db + sw_min_db;
 
   // now, we can map the input to the desired output volume
diff --git a/rtp.c b/rtp.c
index d0f1d1af9a9e72af76df2fd24550289bfdb0de8b..01c7706d6e6629917c1610917dc63f981b06a25f 100644 (file)
--- a/rtp.c
+++ b/rtp.c
@@ -709,7 +709,7 @@ static uint16_t bind_port(int ip_family, const char *self_ip_address, uint32_t s
                           int *sock) {
   // look for a port in the range, if any was specified.
   uint16_t desired_port = config.udp_port_base;
-  int ret;
+  int ret = 0;
 
   int local_socket = socket(ip_family, SOCK_DGRAM, IPPROTO_UDP);
   if (local_socket == -1)