From cdc01b89bf07a5df072d6d0410c4920f857feab7 Mon Sep 17 00:00:00 2001 From: Guy Harris Date: Sun, 16 Jul 2017 20:37:32 -0700 Subject: Rename section comment get/set routines. Rename cf_read_shb_comment() to cf_read_section_comment(); an SHB is a record type in a particular capture file format (pcapng), and not all files that have per-file or per-file-section comments have something called a Section Header Block. Rename cf_update_capture_comment() to cf_update_section_comment(); pcapng, at least, supports multiple sections, although we don't curently support that. This also gives them matching names. Change-Id: Idd8cb0f0fd9125b9626411274aebfb1ec0097665 Reviewed-on: https://code.wireshark.org/review/22659 Reviewed-by: Guy Harris --- file.c | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) (limited to 'file.c') diff --git a/file.c b/file.c index 628bdef674..ffe40991ff 100644 --- a/file.c +++ b/file.c @@ -3804,11 +3804,10 @@ cf_unignore_frame(capture_file *cf, frame_data *frame) } /* - * Read the comment in SHB block + * Read the section comment. */ - const gchar * -cf_read_shb_comment(capture_file *cf) +cf_read_section_comment(capture_file *cf) { wtap_block_t shb_inf; char *shb_comment; @@ -3824,8 +3823,11 @@ cf_read_shb_comment(capture_file *cf) return shb_comment; } +/* + * Modify the section comment. + */ void -cf_update_capture_comment(capture_file *cf, gchar *comment) +cf_update_section_comment(capture_file *cf, gchar *comment) { wtap_block_t shb_inf; gchar *shb_comment; @@ -3943,7 +3945,7 @@ cf_comment_types(capture_file *cf) { guint32 comment_types = 0; - if (cf_read_shb_comment(cf) != NULL) + if (cf_read_section_comment(cf) != NULL) comment_types |= WTAP_COMMENT_PER_SECTION; if (cf->packet_comment_count != 0) comment_types |= WTAP_COMMENT_PER_PACKET; -- cgit v1.2.3