diff --git a/src/common/gamecode/creport.c b/src/common/gamecode/creport.c index 348071816..4b7c9984b 100644 --- a/src/common/gamecode/creport.c +++ b/src/common/gamecode/creport.c @@ -288,7 +288,7 @@ static int cr_skill(const void * v, char * buffer, const void * userdata) { const faction * report = (const faction*)userdata; - skill_t sk = (skill_t)v; + skill_t sk = (skill_t)(int)v; if (sk!=NOSKILL) sprintf(buffer, "\"%s\"", add_translation(skillname(sk, NULL), skillname(sk, report->locale))); else strcpy(buffer, "\"\""); diff --git a/src/common/gamecode/report.c b/src/common/gamecode/report.c index 842ec4f6d..81bf60b94 100644 --- a/src/common/gamecode/report.c +++ b/src/common/gamecode/report.c @@ -3631,7 +3631,7 @@ static void eval_skill(struct opstack ** stack, const void * userdata) { const faction * report = (const faction*)userdata; - int sk = opop(stack, int); + skill_t sk = (skill_t)opop(stack, int); const char * c = skillname(sk, report->locale); opush(stack, strcpy(balloc(strlen(c)+1), c)); } diff --git a/src/common/gamecode/study.c b/src/common/gamecode/study.c index cde1dbcae..9102ca6bd 100644 --- a/src/common/gamecode/study.c +++ b/src/common/gamecode/study.c @@ -477,7 +477,7 @@ learn(void) } /* snotlings können Talente nur bis T8 lernen */ if (u->race == new_race[RC_SNOTLING]){ - if (get_level(u, i) >= 8){ + if (get_level(u, (skill_t)i) >= 8){ cmistake(u, findorder(u, u->thisorder), 308, MSG_EVENT); continue; } diff --git a/src/common/kernel/save.c b/src/common/kernel/save.c index 8b6e668f7..814386d72 100644 --- a/src/common/kernel/save.c +++ b/src/common/kernel/save.c @@ -872,7 +872,7 @@ readgame(boolean backup) w->mode = (unsigned char)ri(F); w->next = pl->watchers; pl->watchers = w; - ur_add((void*)fno, &w->faction, resolve_faction); + ur_add((void*)fno, (void**)&w->faction, resolve_faction); } free(s); }