aboutsummaryrefslogtreecommitdiffstats
path: root/file.c
diff options
context:
space:
mode:
authorGuy Harris <guy@alum.mit.edu>2017-07-16 20:49:01 -0700
committerGuy Harris <guy@alum.mit.edu>2017-07-17 03:49:33 +0000
commit4dd48721ee633fd2db3534ad2e43c00847dce42f (patch)
tree3f6866affdf2e1b12c59ff36746b86a47f640c7c /file.c
parentcdc01b89bf07a5df072d6d0410c4920f857feab7 (diff)
Rename cf_get_comment() to reflect what comment it gets.
Change-Id: Id3b0430a1d462b29833259462536ed4cb0424f77 Reviewed-on: https://code.wireshark.org/review/22662 Reviewed-by: Guy Harris <guy@alum.mit.edu>
Diffstat (limited to 'file.c')
-rw-r--r--file.c12
1 files changed, 10 insertions, 2 deletions
diff --git a/file.c b/file.c
index ffe40991ff..9d178770cd 100644
--- a/file.c
+++ b/file.c
@@ -3865,8 +3865,13 @@ cf_get_user_packet_comment(capture_file *cf, const frame_data *fd)
return NULL;
}
+/*
+ * Get the comment on a packet (record).
+ * If the comment has been edited, it returns the result of the edit,
+ * otherwise it returns the comment from the file.
+ */
char *
-cf_get_comment(capture_file *cf, const frame_data *fd)
+cf_get_packet_comment(capture_file *cf, const frame_data *fd)
{
char *comment;
@@ -3904,10 +3909,13 @@ frame_cmp(gconstpointer a, gconstpointer b, gpointer user_data _U_)
0;
}
+/*
+ * Update(replace) the comment on a capture from a frame
+ */
gboolean
cf_set_user_packet_comment(capture_file *cf, frame_data *fd, const gchar *new_comment)
{
- char *pkt_comment = cf_get_comment(cf, fd);
+ char *pkt_comment = cf_get_packet_comment(cf, fd);
/* Check if the comment has changed */
if (!g_strcmp0(pkt_comment, new_comment)) {