Commit a8a6ac0d a8a6ac0db04dc8416dde3a06fd2da3f5972eb317 by Sergey Poznyakoff

Removed cast from void* to int, it does not work on 64-bit machines.

Besides, pointer comparison on equality/inequality is strictly defined
in C.
1 parent 018c25f5
......@@ -140,7 +140,7 @@ list_remove (list_t list, void *item)
for (previous = &(list->head), current = list->head.next;
current != &(list->head); previous = current, current = current->next)
{
if ((int)current->item == (int)item)
if (current->item == item)
{
previous->next = current->next;
current->next->prev = previous;
......
......@@ -195,7 +195,7 @@ observable_detach (observable_t observable, observer_t observer)
{
event = NULL;
iterator_current (iterator, (void **)&event);
if (event && (int)(event->observer) == (int)observer)
if (event && event->observer == observer)
{
found = 1;
break;
......