]> git.tue.mpg.de Git - paraslash.git/commitdiff
Avoid some gcc warnings.
authorAndre Noll <maan@systemlinux.org>
Sun, 11 Nov 2007 19:23:45 +0000 (20:23 +0100)
committerAndre Noll <maan@systemlinux.org>
Sun, 11 Nov 2007 19:23:45 +0000 (20:23 +0100)
score.c

diff --git a/score.c b/score.c
index 58d219ab8af36b431587cdeaa1e0b5e2e577b79c..7d3b024690d432ee9d4fb9b77a0388fabee90e6b 100644 (file)
--- a/score.c
+++ b/score.c
@@ -132,7 +132,7 @@ int score_add(const struct osl_row *aft_row, long score)
 
        assert(aft_row);
        size = score_table_desc.column_descriptions[SCORECOL_AFT_ROW].data_size;
-       score_objs[SCORECOL_AFT_ROW].data = aft_row;
+       score_objs[SCORECOL_AFT_ROW].data = (struct osl_row *)aft_row;
        score_objs[SCORECOL_AFT_ROW].size = size;
 
        size = score_table_desc.column_descriptions[SCORECOL_SCORE].data_size;
@@ -178,7 +178,8 @@ int score_update(const struct osl_row *aft_row, long percent)
        struct osl_row *row;
        long new_score;
        unsigned n, new_pos;
-       struct osl_object obj = {.data = aft_row, .size = sizeof(aft_row)};
+       struct osl_object obj = {.data = (struct osl_row *)aft_row,
+               .size = sizeof(aft_row)};
        int ret = osl_get_row(score_table, SCORECOL_AFT_ROW, &obj, &row);
 
        if (ret < 0)
@@ -226,7 +227,8 @@ int get_score_and_aft_row(struct osl_row *score_row, long *score,
 static int get_score_row_from_aft_row(const struct osl_row *aft_row,
                struct osl_row **score_row)
 {
-       struct osl_object obj = {.data = aft_row, .size = sizeof(aft_row)};
+       struct osl_object obj = {.data = (struct osl_row *)aft_row,
+               .size = sizeof(aft_row)};
        return osl_get_row(score_table, SCORECOL_AFT_ROW, &obj, score_row);
 
 }