epan: Change export_object_entry_t.payload_len to size_t
The *real* maximum object size is size_t, so change payload_len to match this.
This commit is contained in:
parent
97e5b64f6f
commit
1bb3d761b8
|
@ -23,15 +23,7 @@ typedef struct _export_object_entry_t {
|
|||
gchar *hostname;
|
||||
gchar *content_type;
|
||||
gchar *filename;
|
||||
/* We need to store a 64 bit integer to hold a file length
|
||||
(was guint payload_len;)
|
||||
|
||||
XXX - we store the entire object in the program's address space,
|
||||
so the *real* maximum object size is size_t; if we were to export
|
||||
objects by going through all of the packets containing data from
|
||||
the object, one packet at a time, and write the object incrementally,
|
||||
we could support objects that don't fit into the address space. */
|
||||
gint64 payload_len;
|
||||
size_t payload_len;
|
||||
guint8 *payload_data;
|
||||
} export_object_entry_t;
|
||||
|
||||
|
|
|
@ -2046,7 +2046,7 @@ sharkd_session_process_tap_eo_cb(void *tapdata)
|
|||
|
||||
sharkd_json_value_stringf("_download", "%s_%d", object_list->type, i);
|
||||
|
||||
sharkd_json_value_anyf("len", "%" G_GINT64_FORMAT, eo_entry->payload_len);
|
||||
sharkd_json_value_anyf("len", "%zu", eo_entry->payload_len);
|
||||
|
||||
json_dumper_end_object(&dumper);
|
||||
|
||||
|
@ -4070,7 +4070,7 @@ sharkd_session_process_download(char *buf, const jsmntok_t *tokens, int count)
|
|||
json_dumper_begin_object(&dumper);
|
||||
sharkd_json_value_string("file", filename);
|
||||
sharkd_json_value_string("mime", mime);
|
||||
sharkd_json_value_base64("data", eo_entry->payload_data, (size_t) eo_entry->payload_len);
|
||||
sharkd_json_value_base64("data", eo_entry->payload_data, eo_entry->payload_len);
|
||||
json_dumper_end_object(&dumper);
|
||||
json_dumper_finish(&dumper);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue