Skip to content
Snippets Groups Projects
Commit bbd592cb authored by Mark Grondona's avatar Mark Grondona
Browse files

o small bugs, small fixes

parent 5e6aa46e
No related branches found
No related tags found
No related merge requests found
...@@ -104,16 +104,14 @@ main(int ac, char **av) ...@@ -104,16 +104,14 @@ main(int ac, char **av)
qsw_standalone(job); qsw_standalone(job);
#endif #endif
} else { } else {
resp = allocate_nodes(); if (!(resp = allocate_nodes())) {
info("No nodes allocated. exiting");
exit(1);
}
if (_verbose || _debug) if (_verbose || _debug)
print_job_information(resp); print_job_information(resp);
else else
printf("jobid %d\n", resp->job_id); printf("jobid %d\n", resp->job_id);
if (!resp->node_list) {
info("No nodes allocated. exiting");
exit(1);
}
job = job_create(resp); job = job_create(resp);
create_job_step(job); create_job_step(job);
...@@ -173,11 +171,14 @@ main(int ac, char **av) ...@@ -173,11 +171,14 @@ main(int ac, char **av)
pthread_cond_wait(&job->state_cond, &job->state_mutex); pthread_cond_wait(&job->state_cond, &job->state_mutex);
debug3("main thread woke up, state is now %d", job->state); debug3("main thread woke up, state is now %d", job->state);
} }
pthread_mutex_unlock(&job->state_mutex);
/* job is now overdone, blow this popsicle stand */ /* job is now overdone, blow this popsicle stand */
if (!opt.no_alloc) if (!opt.no_alloc) {
debug("cancelling job %d", job->jobid);
slurm_complete_job(job->jobid); slurm_complete_job(job->jobid);
}
/* kill launch thread */ /* kill launch thread */
pthread_kill(job->lid, SIGTERM); pthread_kill(job->lid, SIGTERM);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment