diff options
author | Jakub Zawadzki <darkjames-ws@darkjames.pl> | 2013-07-21 23:07:33 +0000 |
---|---|---|
committer | Jakub Zawadzki <darkjames-ws@darkjames.pl> | 2013-07-21 23:07:33 +0000 |
commit | c702e92121ec5477ecc25a87b00bf478b42c1dc7 (patch) | |
tree | 962e68606a5718b59153d14ee28c319eb29a904b /ui/cli | |
parent | 74b6c5949957411e5ce95e5e4b1a34997cf31b09 (diff) | |
download | wireshark-c702e92121ec5477ecc25a87b00bf478b42c1dc7.tar.gz wireshark-c702e92121ec5477ecc25a87b00bf478b42c1dc7.tar.bz2 wireshark-c702e92121ec5477ecc25a87b00bf478b42c1dc7.zip |
Replace relative timestamp with reference frame number. Saves 16B per frame.
svn path=/trunk/; revision=50772
Diffstat (limited to 'ui/cli')
-rw-r--r-- | ui/cli/tap-iostat.c | 6 | ||||
-rw-r--r-- | ui/cli/tap-iousers.c | 20 | ||||
-rw-r--r-- | ui/cli/tap-sv.c | 2 |
3 files changed, 14 insertions, 14 deletions
diff --git a/ui/cli/tap-iostat.c b/ui/cli/tap-iostat.c index e1904da766..667377d4a2 100644 --- a/ui/cli/tap-iostat.c +++ b/ui/cli/tap-iostat.c @@ -105,10 +105,10 @@ iostat_packet(void *arg, packet_info *pinfo, epan_dissect_t *edt, const void *du mit = (io_stat_item_t *) arg; parent = mit->parent; - relative_time = ((guint64)pinfo->fd->rel_ts.secs * 1000000ULL) + - ((guint64)((pinfo->fd->rel_ts.nsecs+500)/1000)); + relative_time = ((guint64)pinfo->rel_ts.secs * 1000000ULL) + + ((guint64)((pinfo->rel_ts.nsecs+500)/1000)); if (mit->parent->start_time == 0) { - mit->parent->start_time = pinfo->fd->abs_ts.secs - pinfo->fd->rel_ts.secs; + mit->parent->start_time = pinfo->fd->abs_ts.secs - pinfo->rel_ts.secs; } /* The prev item before the main one is always the last interval we saw packets for */ diff --git a/ui/cli/tap-iousers.c b/ui/cli/tap-iousers.c index 3830eaa321..beeef9084e 100644 --- a/ui/cli/tap-iousers.c +++ b/ui/cli/tap-iousers.c @@ -206,7 +206,7 @@ iousers_udpip_packet(void *arg, packet_info *pinfo, epan_dissect_t *edt _U_, con g_snprintf(name1,256,"%s:%s",ep_address_to_str(&udph->ip_dst),get_udp_port(udph->uh_dport)); } - iousers_process_name_packet(iu, name1, name2, direction, pinfo->fd->pkt_len, &pinfo->fd->rel_ts, &pinfo->fd->abs_ts); + iousers_process_name_packet(iu, name1, name2, direction, pinfo->fd->pkt_len, &pinfo->rel_ts, &pinfo->fd->abs_ts); return 1; } @@ -237,7 +237,7 @@ iousers_sctp_packet(void *arg, packet_info *pinfo, epan_dissect_t *edt _U_, cons g_snprintf(name2,256,"%s:%s",ep_address_to_str(&sctph->ip_dst),s_dport); } - iousers_process_name_packet(iu, name1, name2, direction, pinfo->fd->pkt_len, &pinfo->fd->rel_ts, &pinfo->fd->abs_ts); + iousers_process_name_packet(iu, name1, name2, direction, pinfo->fd->pkt_len, &pinfo->rel_ts, &pinfo->fd->abs_ts); return 1; } @@ -269,7 +269,7 @@ iousers_tcpip_packet(void *arg, packet_info *pinfo, epan_dissect_t *edt _U_, con g_snprintf(name1,256,"%s:%s",ep_address_to_str(&tcph->ip_dst),get_tcp_port(tcph->th_dport)); } - iousers_process_name_packet_with_conv_id(iu, name1, name2, tcph->th_stream, direction, pinfo->fd->pkt_len, &pinfo->fd->rel_ts, &pinfo->fd->abs_ts); + iousers_process_name_packet_with_conv_id(iu, name1, name2, tcph->th_stream, direction, pinfo->fd->pkt_len, &pinfo->rel_ts, &pinfo->fd->abs_ts); return 1; } @@ -281,7 +281,7 @@ iousers_ip_packet(void *arg, packet_info *pinfo, epan_dissect_t *edt _U_, const io_users_t *iu=(io_users_t *)arg; const ws_ip *iph=(const ws_ip *)vip; - iousers_process_address_packet(iu, &iph->ip_src, &iph->ip_dst, pinfo->fd->pkt_len, &pinfo->fd->rel_ts); + iousers_process_address_packet(iu, &iph->ip_src, &iph->ip_dst, pinfo->fd->pkt_len, &pinfo->rel_ts); return 1; } @@ -299,7 +299,7 @@ iousers_ipv6_packet(void *arg, packet_info *pinfo, epan_dissect_t *edt _U_, cons src.data = &ip6h->ip6_src; dst.data = &ip6h->ip6_dst; - iousers_process_address_packet(iu, &src, &dst, pinfo->fd->pkt_len, &pinfo->fd->rel_ts); + iousers_process_address_packet(iu, &src, &dst, pinfo->fd->pkt_len, &pinfo->rel_ts); return 1; } @@ -310,7 +310,7 @@ iousers_ipx_packet(void *arg, packet_info *pinfo, epan_dissect_t *edt _U_, const io_users_t *iu=(io_users_t *)arg; const ipxhdr_t *ipxh=(const ipxhdr_t *)vipx; - iousers_process_address_packet(iu, &ipxh->ipx_src, &ipxh->ipx_dst, pinfo->fd->pkt_len, &pinfo->fd->rel_ts); + iousers_process_address_packet(iu, &ipxh->ipx_src, &ipxh->ipx_dst, pinfo->fd->pkt_len, &pinfo->rel_ts); return 1; } @@ -321,7 +321,7 @@ iousers_fc_packet(void *arg, packet_info *pinfo, epan_dissect_t *edt _U_, const io_users_t *iu=(io_users_t *)arg; const fc_hdr *fchdr=(const fc_hdr *)vfc; - iousers_process_address_packet(iu, &fchdr->s_id, &fchdr->d_id, pinfo->fd->pkt_len, &pinfo->fd->rel_ts); + iousers_process_address_packet(iu, &fchdr->s_id, &fchdr->d_id, pinfo->fd->pkt_len, &pinfo->rel_ts); return 1; } @@ -332,7 +332,7 @@ iousers_eth_packet(void *arg, packet_info *pinfo, epan_dissect_t *edt _U_, const io_users_t *iu=(io_users_t *)arg; const eth_hdr *ehdr=(const eth_hdr *)veth; - iousers_process_address_packet(iu, &ehdr->src, &ehdr->dst, pinfo->fd->pkt_len, &pinfo->fd->rel_ts); + iousers_process_address_packet(iu, &ehdr->src, &ehdr->dst, pinfo->fd->pkt_len, &pinfo->rel_ts); return 1; } @@ -343,7 +343,7 @@ iousers_fddi_packet(void *arg, packet_info *pinfo, epan_dissect_t *edt _U_, cons io_users_t *iu=(io_users_t *)arg; const fddi_hdr *ehdr=(const fddi_hdr *)veth; - iousers_process_address_packet(iu, &ehdr->src, &ehdr->dst, pinfo->fd->pkt_len, &pinfo->fd->rel_ts); + iousers_process_address_packet(iu, &ehdr->src, &ehdr->dst, pinfo->fd->pkt_len, &pinfo->rel_ts); return 1; } @@ -354,7 +354,7 @@ iousers_tr_packet(void *arg, packet_info *pinfo, epan_dissect_t *edt _U_, const io_users_t *iu=(io_users_t *)arg; const tr_hdr *trhdr=(const tr_hdr *)vtr; - iousers_process_address_packet(iu, &trhdr->src, &trhdr->dst, pinfo->fd->pkt_len, &pinfo->fd->rel_ts); + iousers_process_address_packet(iu, &trhdr->src, &trhdr->dst, pinfo->fd->pkt_len, &pinfo->rel_ts); return 1; } diff --git a/ui/cli/tap-sv.c b/ui/cli/tap-sv.c index ccd705a445..8f2960a297 100644 --- a/ui/cli/tap-sv.c +++ b/ui/cli/tap-sv.c @@ -40,7 +40,7 @@ sv_packet(void *prs _U_, packet_info *pinfo, epan_dissect_t *edt _U_, const void int i; const sv_frame_data * sv_data = (const sv_frame_data *)pri; - printf("%f %u ", nstime_to_sec(&pinfo->fd->rel_ts), sv_data->smpCnt); + printf("%f %u ", nstime_to_sec(&pinfo->rel_ts), sv_data->smpCnt); for(i = 0; i < sv_data->num_phsMeas; i++) { printf("%d ", sv_data->phsMeas[i].value); |