mirror of
https://github.com/veracrypt/VeraCrypt.git
synced 2025-11-11 19:08:26 -06:00
Linux: try to fix some rare issues when invoking sudo using fork by waiting 1 second for forked process to start
This commit is contained in:
@@ -458,6 +458,9 @@ namespace VeraCrypt
|
|||||||
adminPassword[request.AdminPassword.size()] = '\n';
|
adminPassword[request.AdminPassword.size()] = '\n';
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#if defined(TC_LINUX )
|
||||||
|
Thread::Sleep (1000); // wait 1 second for the forked sudo to start
|
||||||
|
#endif
|
||||||
if (write (inPipe->GetWriteFD(), &adminPassword.front(), adminPassword.size())) { } // Errors ignored
|
if (write (inPipe->GetWriteFD(), &adminPassword.front(), adminPassword.size())) { } // Errors ignored
|
||||||
|
|
||||||
burn (&adminPassword.front(), adminPassword.size());
|
burn (&adminPassword.front(), adminPassword.size());
|
||||||
|
|||||||
Reference in New Issue
Block a user