diff options
| author | Alexander Gavrilov | 2012-04-20 13:30:37 +0400 |
|---|---|---|
| committer | Alexander Gavrilov | 2012-04-20 13:30:37 +0400 |
| commit | 0a6982f4041f43d571bd2690f148ff369f2d8038 (patch) | |
| tree | 13d60514e341a3bafa36ffa7b8391d1eb5956e38 /plugins/jobutils.cpp | |
| parent | d95cc3435fe249e1c86e5af36b8a10e9009edd97 (diff) | |
| download | dfhack-0a6982f4041f43d571bd2690f148ff369f2d8038.tar.gz dfhack-0a6982f4041f43d571bd2690f148ff369f2d8038.tar.bz2 dfhack-0a6982f4041f43d571bd2690f148ff369f2d8038.tar.xz | |
Enable warnings correctly on linux and fix a lot of them.
Diffstat (limited to 'plugins/jobutils.cpp')
| -rw-r--r-- | plugins/jobutils.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/plugins/jobutils.cpp b/plugins/jobutils.cpp index 51109594..de7f8136 100644 --- a/plugins/jobutils.cpp +++ b/plugins/jobutils.cpp @@ -193,7 +193,7 @@ static bool build_choice_matches(df::ui_build_item_req *req, df::build_req_choic { if (gen->mat_type == new_mat.type && gen->mat_index == new_mat.index && - (ignore_select || gen->used_count < gen->candidates.size())) + (ignore_select || size_t(gen->used_count) < gen->candidates.size())) { return true; } @@ -305,7 +305,7 @@ static df::job_item *getJobItem(color_ostream &out, df::job *job, std::string id return NULL; int v = atoi(idx.c_str()); - if (v < 1 || v > job->job_items.size()) { + if (v < 1 || size_t(v) > job->job_items.size()) { out.printerr("Invalid item index.\n"); return NULL; } |
