diff --git a/src/kits/interface/ColumnTypes.cpp b/src/kits/interface/ColumnTypes.cpp index 8e61228e2e..c06149a3cc 100644 --- a/src/kits/interface/ColumnTypes.cpp +++ b/src/kits/interface/ColumnTypes.cpp @@ -474,7 +474,12 @@ BSizeColumn::DrawField(BField* _field, BRect rect, BView* parent) int BSizeColumn::CompareFields(BField* field1, BField* field2) { - return ((BSizeField*)field1)->Size() - ((BSizeField*)field2)->Size(); + off_t diff = ((BSizeField*)field1)->Size() - ((BSizeField*)field2)->Size(); + if (diff > 0) + return 1; + if (diff < 0) + return -1; + return 0; }