diff --git a/src/mavsdk/plugins/ftp/ftp_impl.cpp b/src/mavsdk/plugins/ftp/ftp_impl.cpp index af84acfee2..74bde0341b 100644 --- a/src/mavsdk/plugins/ftp/ftp_impl.cpp +++ b/src/mavsdk/plugins/ftp/ftp_impl.cpp @@ -95,7 +95,7 @@ void FtpImpl::list_directory_async(const std::string& path, Ftp::ListDirectoryCa Ftp::Result FtpImpl::create_directory(const std::string& path) { - std::promise prom; + std::promise prom{}; auto fut = prom.get_future(); create_directory_async(path, [&](Ftp::Result result) { prom.set_value(result); }); @@ -113,7 +113,7 @@ void FtpImpl::create_directory_async(const std::string& path, Ftp::ResultCallbac Ftp::Result FtpImpl::remove_directory(const std::string& path) { - std::promise prom; + std::promise prom{}; auto fut = prom.get_future(); remove_directory_async(path, [&](Ftp::Result result) { prom.set_value(result); }); @@ -153,7 +153,7 @@ void FtpImpl::remove_file_async(const std::string& path, Ftp::ResultCallback cal Ftp::Result FtpImpl::rename(const std::string& from_path, const std::string& to_path) { - std::promise prom; + std::promise prom{}; auto fut = prom.get_future(); rename_async(from_path, to_path, [&](Ftp::Result result) { prom.set_value(result); }); @@ -174,7 +174,7 @@ void FtpImpl::rename_async( std::pair FtpImpl::are_files_identical(const std::string& local_path, const std::string& remote_path) { - std::promise> prom; + std::promise> prom{}; auto fut = prom.get_future(); are_files_identical_async(local_path, remote_path, [&](Ftp::Result result, bool identical) {