\#10 Address compiler warnings
This commit is contained in:
@ -42,18 +42,8 @@ list_objects(int /* argc */, char * /* argv */[],
|
||||
|
||||
if (pt == provider_type::s3) {
|
||||
lock_data lock(pt, unique_id);
|
||||
const auto res = lock.grab_lock(1u);
|
||||
/* if (res == lock_result::locked) { */
|
||||
/* auto port = app_config::default_api_port(pt); */
|
||||
/* utils::cli::get_api_authentication_data(user, password, port, pt,
|
||||
* data_directory); */
|
||||
/* const auto response = */
|
||||
/* client({"localhost", password, port,
|
||||
* user}).create_directory(api_path); */
|
||||
/* std::cout << static_cast<int>(response.response_type) << std::endl; */
|
||||
/* std::cout << response.data.dump(2) << std::endl; */
|
||||
/* } else */
|
||||
if (res == lock_result::success) {
|
||||
auto lock_res = lock.grab_lock(1u);
|
||||
if (lock_res == lock_result::success) {
|
||||
app_config config(pt, data_directory);
|
||||
s3_comm comm(config);
|
||||
std::vector<directory_item> list{};
|
||||
@ -67,7 +57,7 @@ list_objects(int /* argc */, char * /* argv */[],
|
||||
std::cout << api_error_to_string(res) << std::endl;
|
||||
}
|
||||
} else {
|
||||
std::cout << "failed to grab lock: '" << static_cast<int>(res) << "'"
|
||||
std::cout << "failed to grab lock: '" << static_cast<int>(lock_res) << "'"
|
||||
<< std::endl;
|
||||
ret = exit_code::lock_failed;
|
||||
}
|
||||
|
Reference in New Issue
Block a user