Fix GCC enum/int comparison warning