What do you think of this bubble sorting function in C, for a string array? I would like to improve the readability, performance, and any good practices.
void sort_entries(char **entries, int reverse)
{
char **next;
char **previous;
char *t;
int value;
previous = tab;
while (*(next = previous + 1))
{
value = strcasecmp(*previous, *next);
if ((!reverse && value > 0)
|| (reverse && value < 0))
{
t = *previous;
*previous = *next;
*next = t;
previous = entries;
continue ;
}
previous++;
}
}