diff options
author | Michael Mann <mmann78@netscape.net> | 2015-06-26 23:00:33 -0400 |
---|---|---|
committer | Michael Mann <mmann78@netscape.net> | 2015-06-29 02:11:04 +0000 |
commit | da09a1bfd86c2066ab492178bd2c0faa96bfd579 (patch) | |
tree | d0855286253963750b272e04ec2e57b56c9bfee1 /epan/column-info.h | |
parent | b9145bc836daafd6cad960b95e9d2144781e7317 (diff) |
Take all epan_column_info members that always get allocated to "number of columns" to share their own data structure.
Change-Id: Ib982662db6cf68730a7d121eac60d9bc5ae67429
Reviewed-on: https://code.wireshark.org/review/9195
Petri-Dish: Michael Mann <mmann78@netscape.net>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
Reviewed-by: Michael Mann <mmann78@netscape.net>
Diffstat (limited to 'epan/column-info.h')
-rw-r--r-- | epan/column-info.h | 25 |
1 files changed, 15 insertions, 10 deletions
diff --git a/epan/column-info.h b/epan/column-info.h index 81d4888e51..5d2a242918 100644 --- a/epan/column-info.h +++ b/epan/column-info.h @@ -43,22 +43,27 @@ typedef struct { gchar **col_expr_val; /**< Value for filter expression */ } col_expr_t; +/** Individual column info */ +typedef struct { + gint col_fmt; /**< Format of column */ + gboolean *fmt_matx; /**< Specifies which formats apply to a column */ + gchar *col_title; /**< Column titles */ + gchar *col_custom_field; /**< Custom column field */ + gint col_custom_occurrence;/**< Custom column field occurrence */ + GSList *col_custom_field_ids; /**< Custom column field id */ + struct epan_dfilter *col_custom_dfilter; /**< Compiled custom column field */ + const gchar *col_data; /**< Column data */ + gchar *col_buf; /**< Buffer into which to copy data for column */ + int col_fence; /**< Stuff in column buffer before this index is immutable */ +} col_item_t; + /** Column info */ struct epan_column_info { const struct epan_session *epan; gint num_cols; /**< Number of columns */ - gint *col_fmt; /**< Format of column */ - gboolean **fmt_matx; /**< Specifies which formats apply to a column */ + col_item_t *columns; /**< All column data */ gint *col_first; /**< First column number with a given format */ gint *col_last; /**< Last column number with a given format */ - gchar **col_title; /**< Column titles */ - gchar **col_custom_field; /**< Custom column field */ - gint *col_custom_occurrence;/**< Custom column field occurrence */ - GSList **col_custom_field_ids; /**< Custom column field id */ - struct epan_dfilter **col_custom_dfilter; /**< Compiled custom column field */ - const gchar **col_data; /**< Column data */ - gchar **col_buf; /**< Buffer into which to copy data for column */ - int *col_fence; /**< Stuff in column buffer before this index is immutable */ col_expr_t col_expr; /**< Column expressions and values */ gboolean writable; /**< writable or not @todo Are we still writing to the columns? */ }; |