mirror of
https://github.com/fergalmoran/ladybird.git
synced 2025-12-25 19:04:58 +00:00
LibGUI: Remove unnecessary type cast in JsonArrayModel.
Since TCP sequence numbers are randomly choosen 32-bit numbers, it often happend that the most significant bit was set. The cast to a 32-bit signed integer then made the number negative. Thus TCP sequence were shown negative in the SystemMonitor every so often.
This commit is contained in:
@@ -107,7 +107,7 @@ Variant JsonArrayModel::data(const ModelIndex& index, ModelRole role) const
|
||||
if (field_spec.massage_for_display)
|
||||
return field_spec.massage_for_display(object);
|
||||
if (data.is_number())
|
||||
return data.to_i32();
|
||||
return data;
|
||||
return object.get(json_field_name).to_string();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user