mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-12-28 04:33:05 +00:00
Avoid temporary construction and potential for corrupted data access.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@35771 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
84c8a9c592
commit
7b57fe3554
@ -49,10 +49,9 @@ void CLIDebugger::startProgramRunning() {
|
||||
eliminateRunInfo();
|
||||
|
||||
// If the program has been modified, reload it!
|
||||
sys::Path Program(Dbg.getProgramPath());
|
||||
sys::PathWithStatus Program(Dbg.getProgramPath());
|
||||
std::string Err;
|
||||
const sys::FileStatus *Status =
|
||||
sys::PathWithStatus(Program).getFileStatus(false, &Err);
|
||||
const sys::FileStatus *Status = Program.getFileStatus(false, &Err);
|
||||
if (!Status)
|
||||
throw Err;
|
||||
if (TheProgramInfo->getProgramTimeStamp() != Status->getTimestamp()) {
|
||||
|
Loading…
Reference in New Issue
Block a user