From 7ee0db108058625bbea758f20373db0df32c2613 Mon Sep 17 00:00:00 2001 From: Ulf Lamping Date: Mon, 18 Apr 2005 22:05:56 +0000 Subject: statusbar changes: -show the current capture file size, if capturing in real time mode. -move the packet "Drops" count (if available) from file to packets statusbar part svn path=/trunk/; revision=14130 --- file.c | 15 +-------------- 1 file changed, 1 insertion(+), 14 deletions(-) (limited to 'file.c') diff --git a/file.c b/file.c index f4055d7ed9..dd624f8771 100644 --- a/file.c +++ b/file.c @@ -625,20 +625,6 @@ cf_finish_tail(capture_file *cf, int *err) } #endif /* HAVE_LIBPCAP */ - -/* update the f_len field */ -cf_update_f_len(capture_file *cf) { - int fd; - struct stat cf_stat; - - - fd = wtap_fd(cf->wth); - if (fstat(fd, &cf_stat) >= 0) { - cf->f_len = cf_stat.st_size; - } -} - - const gchar * cf_get_display_name(capture_file *cf) { @@ -908,6 +894,7 @@ read_packet(capture_file *cf, long offset) cf->plist_end = fdata; cf->count++; + cf->f_len = offset + phdr->caplen; fdata->num = cf->count; add_packet_to_packet_list(fdata, cf, pseudo_header, buf, TRUE); } else { -- cgit v1.2.3