diff --git a/libs/util/info.c b/libs/util/info.c index f619a1a81..9e2f056df 100644 --- a/libs/util/info.c +++ b/libs/util/info.c @@ -100,7 +100,8 @@ Info_SetValueForStarKey (info_t *info, const char *key, const char *value, { info_key_t *k; int cursize; - char *str, *d, *s; + char *str; + byte *d, *s; if (strstr (key, "\\") || strstr (value, "\\")) { Sys_Printf ("Can't use keys or values with a \\\n"); @@ -176,7 +177,7 @@ Info_Print (info_t *info) info_key_t **key_list; info_key_t **key; - key_list = (info_key_t **)Hash_GetList (info->tab); + key_list = (info_key_t **) Hash_GetList (info->tab); for (key = key_list; *key; key++) { Sys_Printf ("%-15s %s\n", (*key)->key, (*key)->value); @@ -193,9 +194,9 @@ info_get_key (void *k, void *unused) static void free_key (void *_k, void *unused) { - info_key_t *k = (info_key_t *)_k; - free ((char*)k->key); - free ((char*)k->value); + info_key_t *k = (info_key_t *) _k; + free ((char *) k->key); + free ((char *) k->value); free (k); } @@ -226,7 +227,7 @@ Info_ParseString (const char *s, int maxsize, int flags) if (*end) *end++ = 0; } else { - value = end = (char *)""; + value = end = (char *) ""; } Info_SetValueForStarKey (info, key, value, flags); key = end; @@ -242,7 +243,7 @@ Info_Destroy (info_t *info) } char * -Info_MakeString (info_t *info, int (*filter)(const char *)) +Info_MakeString (info_t *info, int (*filter) (const char *)) { char *string; const char *s; @@ -251,7 +252,7 @@ Info_MakeString (info_t *info, int (*filter)(const char *)) info_key_t **key; d = string = Hunk_TempAlloc (info->cursize + 1); - key_list = (info_key_t **)Hash_GetList (info->tab); + key_list = (info_key_t **) Hash_GetList (info->tab); for (key = key_list; *key; key++) { if (!*(*key)->value) diff --git a/libs/util/msg.c b/libs/util/msg.c index 0fedc961a..2c2d4889b 100644 --- a/libs/util/msg.c +++ b/libs/util/msg.c @@ -261,7 +261,7 @@ MSG_ReadString (qmsg_t *msg) return ""; } - string = (char *) &msg->message->data[msg->readcount]; + string = &msg->message->data[msg->readcount]; maxlen = msg->message->cursize - msg->readcount; len = strnlen (string, maxlen); diff --git a/libs/util/qfplist.c b/libs/util/qfplist.c index 5bc7603c3..34da7248a 100644 --- a/libs/util/qfplist.c +++ b/libs/util/qfplist.c @@ -59,7 +59,7 @@ init_quotables (void) { const char *unquotables = "0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ" "abcdefghijklmnopqrstuvwxyz!#$%&*+-./:?@|~_^"; - const char *c; + const byte *c; memset (quotable_bitmap, ~0, sizeof (quotable_bitmap)); for (c = unquotables; *c; c++) quotable_bitmap[*c / 8] &= ~(1 << (*c % 8));