Skip to content

Commit e8a3e12

Browse files
author
Ivan Stoev
committed
Fixing loging with empty password
1 parent c656897 commit e8a3e12

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

pCloudCC/pclsync_lib.cpp

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -174,6 +174,9 @@ static void status_change(pstatus_t* status) {
174174
std::cout << "Down: " << status->downloadstr << "| Up: " << status->uploadstr <<", status is " << status2string(status->status) << std::endl;
175175
*clib::pclsync_lib::get_lib().status_ = *status;
176176
if (status->status==PSTATUS_LOGIN_REQUIRED){
177+
if (clib::pclsync_lib::get_lib().get_password().empty())
178+
clib::pclsync_lib::get_lib().get_pass_from_console();
179+
//std::cout << "Username: " << clib::pclsync_lib::get_lib().get_username().c_str() << "| Password: " << clib::pclsync_lib::get_lib().get_password().c_str() << std::endl;
177180
psync_set_user_pass(clib::pclsync_lib::get_lib().get_username().c_str(), clib::pclsync_lib::get_lib().get_password().c_str(), (int) clib::pclsync_lib::get_lib().save_pass_);
178181
std::cout << "logging in" << std::endl;
179182
}

0 commit comments

Comments
 (0)