Utils: added max_field_length function