Some small fixes

This commit is contained in:
David Anderson 2021-03-11 21:39:47 -08:00
parent 5310652f30
commit 0d51497ec0
2 changed files with 4 additions and 5 deletions

View File

@ -669,7 +669,9 @@ bool ACTIVE_TASK::temporary_exit_file_present(
x = y;
}
char *p = fgets(buf, 256, f); // read the \n
p = fgets(buf, 256, f);
if (p) {
p = fgets(buf, 256, f);
}
if (p == NULL) {
fclose(f);
return false;

View File

@ -1066,6 +1066,7 @@ int ACTIVE_TASK::start(bool test) {
// hook up stderr to a specially-named file
//
if (freopen(STDERR_FILE, "a", stderr) == NULL) {
_exit(errno);
}
// lower our priority if needed
@ -1250,10 +1251,6 @@ void run_test_app() {
RESULT result;
int retval;
char buf[256];
if (getcwd(buf, sizeof(buf)) == NULL) { // so we can see where we're running
}
gstate.run_test_app = true;
wu.project = &project;