diff options
author | sinanmohd <sinan@sinanmohd.com> | 2024-07-28 18:28:35 +0530 |
---|---|---|
committer | sinanmohd <sinan@sinanmohd.com> | 2024-07-28 18:28:35 +0530 |
commit | 82f404f66eb2f25ac3125fac4d45ba62673ebf36 (patch) | |
tree | f29d580bb9c73a75a9aebc4716aaccc931aa5914 | |
parent | 0b1604635644ab613a4ea96cf616373ea4363ad3 (diff) |
jobs: scheduled -> requested
-rw-r--r-- | include/jobs.h | 2 | ||||
-rw-r--r-- | src/jobs.c | 2 | ||||
-rw-r--r-- | src/queue.c | 6 | ||||
-rw-r--r-- | src/solver_highs.c | 2 |
4 files changed, 6 insertions, 6 deletions
diff --git a/include/jobs.h b/include/jobs.h index 2610c7b..e6ad25d 100644 --- a/include/jobs.h +++ b/include/jobs.h @@ -12,7 +12,7 @@ struct output { struct job { char *name, *drv_path, *nix_attr_name; - bool scheduled; + bool requested; bool insubstituters; size_t outputs_size, outputs_filled; struct output **outputs; @@ -442,7 +442,7 @@ static int job_new(struct job **j, char *name, char *drv_path, char *attr, print_err("%s", strerror(errno)); return -errno; } - job->scheduled = false; + job->requested = false; job->id = -1; job->outputs_size = 0; diff --git a/src/queue.c b/src/queue.c index c3ae7ee..bbfbb0f 100644 --- a/src/queue.c +++ b/src/queue.c @@ -43,7 +43,7 @@ static int queue_dag_isolate(struct job *job, struct job *keep_parent, job->parents_filled = 0; } - if (job->scheduled) + if (job->requested) CIRCLEQ_REMOVE(jobs, job, clist); HASH_DEL(*htab, job); @@ -186,8 +186,8 @@ static int queue_push(struct queue *queue, struct job *job) } /* no duplicate entries in queue */ - if (!job->scheduled) { - job->scheduled = true; + if (!job->requested) { + job->requested = true; CIRCLEQ_INSERT_TAIL(&queue->jobs, job, clist); } pthread_mutex_unlock(&queue->mutex); diff --git a/src/solver_highs.c b/src/solver_highs.c index 214fb8d..0e8b0cb 100644 --- a/src/solver_highs.c +++ b/src/solver_highs.c @@ -33,7 +33,7 @@ static int solver_highs_unwrapped(double *solution, struct job_clist *q, return -errno; } for (size_t i = 0; i < jobid->filled; i++) { - if (jobid->jobs[i]->scheduled) + if (jobid->jobs[i]->requested) col_profit[i] = 1.0; } |