diff --git a/src/mac/carbon/macnotfy.cpp b/src/mac/carbon/macnotfy.cpp index 507605510d..f8e077ce81 100644 --- a/src/mac/carbon/macnotfy.cpp +++ b/src/mac/carbon/macnotfy.cpp @@ -101,11 +101,11 @@ void wxMacRemoveAllNotifiersForData( wxMacNotifierTableRef table , void* data ) while ( e->top != index ) { - if ( index == kMaxEvents ) - index = 0 ; if ( e->data[index] == data ) e->data[index] = NULL ; index++ ; + if ( index == kMaxEvents ) + index = 0 ; } } diff --git a/src/mac/macnotfy.cpp b/src/mac/macnotfy.cpp index 507605510d..f8e077ce81 100644 --- a/src/mac/macnotfy.cpp +++ b/src/mac/macnotfy.cpp @@ -101,11 +101,11 @@ void wxMacRemoveAllNotifiersForData( wxMacNotifierTableRef table , void* data ) while ( e->top != index ) { - if ( index == kMaxEvents ) - index = 0 ; if ( e->data[index] == data ) e->data[index] = NULL ; index++ ; + if ( index == kMaxEvents ) + index = 0 ; } }