# HG changeset patch # User Matti Hamalainen # Date 1192843861 -10800 # Node ID a8950cdd20414a7696845035cb7744d2e9252055 # Parent 80996bb4213fd20b3b9d3fe2bea16484ea261891 Use gssize instead of size_t. diff -r 80996bb4213f -r a8950cdd2041 src/audacious/tuple_compiler.c --- a/src/audacious/tuple_compiler.c Sat Oct 20 04:21:33 2007 +0300 +++ b/src/audacious/tuple_compiler.c Sat Oct 20 04:31:01 2007 +0300 @@ -212,10 +212,10 @@ static gboolean tc_get_item(TupleEvalContext *ctx, - gchar **str, gchar *buf, size_t max, + gchar **str, gchar *buf, gssize max, gchar endch, gboolean *literal, gchar *errstr, gchar *item) { - size_t i = 0; + gssize i = 0; gchar *s = *str, tmpendch; assert(str != NULL); assert(buf != NULL); @@ -467,7 +467,7 @@ /* Function? */ item = c++; if (*c == '{') { - size_t i = 0; + gssize i = 0; c++; while (*c != '\0' && (isalnum(*c) || *c == '-') && *c != '}' && *c != ':' && i < (MAX_STR - 1)) @@ -488,7 +488,7 @@ } } else { /* Parse raw/literal text */ - size_t i = 0; + gssize i = 0; while (*c != '\0' && *c != '$' && *c != '%' && *c != '}' && i < (MAX_STR - 1)) { if (*c == '\\') c++; tmps1[i++] = *(c++); @@ -601,7 +601,7 @@ /* Evaluate tuple in given TupleEval expression in given * context and return resulting string. */ -static gboolean tuple_formatter_eval_do(TupleEvalContext *ctx, TupleEvalNode *expr, Tuple *tuple, gchar **res, size_t *resmax, size_t *reslen) +static gboolean tuple_formatter_eval_do(TupleEvalContext *ctx, TupleEvalNode *expr, Tuple *tuple, gchar **res, gssize *resmax, gssize *reslen) { TupleEvalNode *curr = expr; gchar tmps[MAX_STR], *tmps2; @@ -756,7 +756,7 @@ gchar *tuple_formatter_eval(TupleEvalContext *ctx, TupleEvalNode *expr, Tuple *tuple) { gchar *res = g_strdup(""); - size_t resmax = 0, reslen = 0; + gssize resmax = 0, reslen = 0; assert(ctx != NULL); assert(tuple != NULL);