From 2a088c1d53ee1e1e3012f68aea745324a44e8120 Mon Sep 17 00:00:00 2001 From: Guy Harris Date: Wed, 6 Nov 2013 20:39:09 +0000 Subject: [PATCH] Add support for displaying dates as year and day-of-year (1-origin). In the process, fix various man page descriptions of the -t flag, and add support for UTC absolute times in the iousers and iostat TShark taps. svn path=/trunk/; revision=53114 --- doc/rawshark.pod | 40 +++-- doc/tshark.pod | 29 ++-- doc/wireshark.pod.template | 29 ++-- epan/column-info.h | 124 ++++++++-------- epan/column-utils.c | 219 ++++++++++++++++++++++----- epan/column.c | 293 +++++++++++++++++++++---------------- epan/frame_data.c | 12 +- epan/timestamp.h | 10 +- epan/wslua/wslua_pinfo.c | 6 +- rawshark.c | 20 ++- tshark.c | 30 ++-- ui/cli/tap-iostat.c | 70 +++++++-- ui/cli/tap-iousers.c | 50 ++++++- ui/gtk/main.c | 21 ++- ui/gtk/main_menubar.c | 12 +- 15 files changed, 665 insertions(+), 300 deletions(-) diff --git a/doc/rawshark.pod b/doc/rawshark.pod index 8d985bbc41..2eae524821 100644 --- a/doc/rawshark.pod +++ b/doc/rawshark.pod @@ -18,7 +18,7 @@ S<[ B<-r> EpipeE|- ]> S<[ B<-R> Eread (display) filterE ]> S<[ B<-s> ]> S<[ B<-S> Efield formatE ]> -S<[ B<-t> ad|a|r|d|e ]> +S<[ B<-t> a|ad|adoy|d|dd|e|r|u|ud|udoy ]> S<[ B<-v> ]> =head1 DESCRIPTION @@ -217,25 +217,45 @@ B<%S> String value of the field. For something similar to Wireshark's standard display ("Type: A (1)") you could use B<%D: %S (%N)>. -=item -t ad|a|r|d|e +=item -t a|ad|adoy|d|dd|e|r|u|ud|udoy -Set the format of the packet timestamp printed in summary lines, the default -is relative. The format can be one of: +Set the format of the packet timestamp printed in summary lines. +The format can be one of: -B absolute with date: The absolute date and time is the actual time and -date the packet was captured +B absolute: The absolute time, as local time in your time zone, +is the actual time the packet was captured, with no date displayed -B absolute: The absolute time is the actual time the packet was captured, -with no date displayed +B absolute with date: The absolute date, displayed as YYYY-MM-DD, +and time, as local time in your time zone, is the actual time and date +the packet was captured -B relative: The relative time is the time elapsed between the first packet -and the current packet +B absolute with date using day of year: The absolute date, +displayed as YYYY/DOY, and time, as local time in your time zone, +is the actual time and date the packet was captured B delta: The delta time is the time since the previous packet was captured +B
delta_displayed: The delta_displayed time is the time since the +previous displayed packet was captured + B epoch: The time in seconds since epoch (Jan 1, 1970 00:00:00) +B relative: The relative time is the time elapsed between the first packet +and the current packet + +B UTC: The absolute time, as UTC, is the actual time the packet was +captured, with no date displayed + +B UTC with date: The absolute date, displayed as YYYY-MM-DD, +and time, as UTC, is the actual time and date the packet was captured + +B UTC with date using day of year: The absolute date, displayed +as YYYY/DOY, and time, as UTC, is the actual time and date the packet +was captured + +The default format is relative. + =item -v Print the version and exit. diff --git a/doc/tshark.pod b/doc/tshark.pod index d50447b9c6..10a3feb4bb 100644 --- a/doc/tshark.pod +++ b/doc/tshark.pod @@ -38,7 +38,7 @@ S<[ B<-r> EinfileE ]> S<[ B<-R> ERead filterE ]> S<[ B<-s> Ecapture snaplenE ]> S<[ B<-S> EseparatorE ]> -S<[ B<-t> a|ad|d|dd|e|r|u|ud ]> +S<[ B<-t> a|ad|adoy|d|dd|e|r|u|ud|udoy ]> S<[ B<-T> pdml|psml|ps|text|fields ]> S<[ B<-v> ]> S<[ B<-V> ]> @@ -665,16 +665,21 @@ the default snapshot length is used if provided. Set the line separator to be printed between packets. -=item -t a|ad|d|dd|e|r|u|ud +=item -t a|ad|adoy|d|dd|e|r|u|ud|udoy Set the format of the packet timestamp printed in summary lines. The format can be one of: -B absolute: The absolute time is the actual time the packet was captured, -with no date displayed +B absolute: The absolute time, as local time in your time zone, +is the actual time the packet was captured, with no date displayed -B absolute with date: The absolute date and time is the actual time and -date the packet was captured +B absolute with date: The absolute date, displayed as YYYY-MM-DD, +and time, as local time in your time zone, is the actual time and date +the packet was captured + +B absolute with date using day of year: The absolute date, +displayed as YYYY/DOY, and time, as local time in your time zone, +is the actual time and date the packet was captured B delta: The delta time is the time since the previous packet was captured @@ -687,11 +692,15 @@ B epoch: The time in seconds since epoch (Jan 1, 1970 00:00:00) B relative: The relative time is the time elapsed between the first packet and the current packet -B UTC: The UTC time is the actual time the packet was captured, -with no date displayed +B UTC: The absolute time, as UTC, is the actual time the packet was +captured, with no date displayed -B UTC with date: The UTC date and time is the actual time and -date the packet was captured +B UTC with date: The absolute date, displayed as YYYY-MM-DD, +and time, as UTC, is the actual time and date the packet was captured + +B UTC with date using day of year: The absolute date, displayed +as YYYY/DOY, and time, as UTC, is the actual time and date the packet +was captured The default format is relative. diff --git a/doc/wireshark.pod.template b/doc/wireshark.pod.template index c36c246821..8a0e584918 100644 --- a/doc/wireshark.pod.template +++ b/doc/wireshark.pod.template @@ -40,7 +40,7 @@ S<[ B<-r> EinfileE ]> S<[ B<-R> Eread (display) filterE ]> S<[ B<-s> Ecapture snaplenE ]> S<[ B<-S> ]> -S<[ B<-t> a|ad|d|dd|e|r|u|ud ]> +S<[ B<-t> a|ad|adoy|d|dd|e|r|u|ud|udoy ]> S<[ B<-v> ]> S<[ B<-w> EoutfileE ]> S<[ B<-X> EeXtension optionE ]> @@ -549,16 +549,21 @@ the default snapshot length is used if provided. Automatically update the packet display as packets are coming in. -=item -t a|ad|d|dd|e|r|u|ud +=item -t a|ad|adoy|d|dd|e|r|u|ud|udoy Set the format of the packet timestamp displayed in the packet list window. The format can be one of: -B absolute: The absolute time is the actual time the packet was captured, -with no date displayed +B absolute: The absolute time, as local time in your time zone, +is the actual time the packet was captured, with no date displayed -B absolute with date: The absolute date and time is the actual time and -date the packet was captured +B absolute with date: The absolute date, displayed as YYYY-MM-DD, +and time, as local time in your time zone, is the actual time and date +the packet was captured + +B absolute with date using day of year: The absolute date, +displayed as YYYY/DOY, and time, as local time in your time zone, +is the actual time and date the packet was captured B delta: The delta time is the time since the previous packet was captured @@ -571,11 +576,15 @@ B epoch: The time in seconds since epoch (Jan 1, 1970 00:00:00) B relative: The relative time is the time elapsed between the first packet and the current packet -B UTC: The UTC time is the actual time the packet was captured, -with no date displayed +B UTC: The absolute time, as UTC, is the actual time the packet was +captured, with no date displayed -B UTC with date: The UTC date and time is the actual time and -date the packet was captured +B UTC with date: The absolute date, displayed as YYYY-MM-DD, +and time, as UTC, is the actual time and date the packet was captured + +B UTC with date using day of year: The absolute date, displayed +as YYYY/DOY, and time, as UTC, is the actual time and date the packet +was captured The default format is relative. diff --git a/epan/column-info.h b/epan/column-info.h index 6cfb695a2a..c4f70adac7 100644 --- a/epan/column-info.h +++ b/epan/column-info.h @@ -75,67 +75,69 @@ typedef struct _column_info { */ enum { COL_8021Q_VLAN_ID, /**< 0) 802.1Q vlan ID */ - COL_ABS_DATE_TIME, /**< 1) Absolute date and time */ - COL_ABS_TIME, /**< 2) Absolute time */ - COL_CIRCUIT_ID, /**< 3) Circuit ID */ - COL_DSTIDX, /**< 4) !! DEPRECATED !! - Dst port idx - Cisco MDS-specific */ - COL_SRCIDX, /**< 5) !! DEPRECATED !! - Src port idx - Cisco MDS-specific */ - COL_VSAN, /**< 6) VSAN - Cisco MDS-specific */ - COL_CUMULATIVE_BYTES, /**< 7) Cumulative number of bytes */ - COL_CUSTOM, /**< 8) Custom column (any filter name's contents) */ - COL_DCE_CALL, /**< 9) DCE/RPC connection oriented call id OR datagram sequence number */ - COL_DCE_CTX, /**< 10) !! DEPRECATED !! - DCE/RPC connection oriented context id */ - COL_DELTA_TIME, /**< 11) Delta time */ - COL_DELTA_CONV_TIME,/**< 12) Delta time to last frame in conversation */ - COL_DELTA_TIME_DIS, /**< 13) Delta time displayed*/ - COL_RES_DST, /**< 14) Resolved dest */ - COL_UNRES_DST, /**< 15) Unresolved dest */ - COL_RES_DST_PORT, /**< 16) Resolved dest port */ - COL_UNRES_DST_PORT, /**< 17) Unresolved dest port */ - COL_DEF_DST, /**< 18) Destination address */ - COL_DEF_DST_PORT, /**< 19) Destination port */ - COL_EXPERT, /**< 20) Expert Info */ - COL_IF_DIR, /**< 21) FW-1 monitor interface/direction */ - COL_OXID, /**< 22) !! DEPRECATED !! - Fibre Channel OXID */ - COL_RXID, /**< 23) !! DEPRECATED !! - Fibre Channel RXID */ - COL_FR_DLCI, /**< 24) !! DEPRECATED !! - Frame Relay DLCI */ - COL_FREQ_CHAN, /**< 25) IEEE 802.11 (and WiMax?) - Channel */ - COL_BSSGP_TLLI, /**< 26) !! DEPRECATED !! - GPRS BSSGP IE TLLI */ - COL_HPUX_DEVID, /**< 27) !! DEPRECATED !! - HP-UX Nettl Device ID */ - COL_HPUX_SUBSYS, /**< 28) !! DEPRECATED !! - HP-UX Nettl Subsystem */ - COL_DEF_DL_DST, /**< 29) Data link layer dest address */ - COL_DEF_DL_SRC, /**< 30) Data link layer source address */ - COL_RES_DL_DST, /**< 31) Resolved DL dest */ - COL_UNRES_DL_DST, /**< 32) Unresolved DL dest */ - COL_RES_DL_SRC, /**< 33) Resolved DL source */ - COL_UNRES_DL_SRC, /**< 34) Unresolved DL source */ - COL_RSSI, /**< 35) IEEE 802.11 - received signal strength */ - COL_TX_RATE, /**< 36) IEEE 802.11 - TX rate in Mbps */ - COL_DSCP_VALUE, /**< 37) IP DSCP Value */ - COL_INFO, /**< 38) Description */ - COL_COS_VALUE, /**< 39) !! DEPRECATED !! - L2 COS Value */ - COL_RES_NET_DST, /**< 40) Resolved net dest */ - COL_UNRES_NET_DST, /**< 41) Unresolved net dest */ - COL_RES_NET_SRC, /**< 42) Resolved net source */ - COL_UNRES_NET_SRC, /**< 43) Unresolved net source */ - COL_DEF_NET_DST, /**< 44) Network layer dest address */ - COL_DEF_NET_SRC, /**< 45) Network layer source address */ - COL_NUMBER, /**< 46) Packet list item number */ - COL_PACKET_LENGTH, /**< 47) Packet length in bytes */ - COL_PROTOCOL, /**< 48) Protocol */ - COL_REL_TIME, /**< 49) Relative time */ - COL_REL_CONV_TIME, /**< 50) !! DEPRECATED !! - Relative time to beginning of conversation */ - COL_DEF_SRC, /**< 51) Source address */ - COL_DEF_SRC_PORT, /**< 52) Source port */ - COL_RES_SRC, /**< 53) Resolved source */ - COL_UNRES_SRC, /**< 54) Unresolved source */ - COL_RES_SRC_PORT, /**< 55) Resolved source port */ - COL_UNRES_SRC_PORT, /**< 56) Unresolved source port */ - COL_TEI, /**< 57) Q.921 TEI */ - COL_UTC_DATE_TIME, /**< 58) UTC date and time */ - COL_UTC_TIME, /**< 59) UTC time */ - COL_CLS_TIME, /**< 60) Command line-specified time (default relative) */ - NUM_COL_FMTS /**< 61) Should always be last */ + COL_ABS_YMD_TIME, /**< 1) Absolute date, as YYYY-MM-DD, and time */ + COL_ABS_YDOY_TIME, /**< 2) Absolute date, as YYYY/DOY, and time */ + COL_ABS_TIME, /**< 3) Absolute time */ + COL_CIRCUIT_ID, /**< 4) Circuit ID */ + COL_DSTIDX, /**< 5) !! DEPRECATED !! - Dst port idx - Cisco MDS-specific */ + COL_SRCIDX, /**< 6) !! DEPRECATED !! - Src port idx - Cisco MDS-specific */ + COL_VSAN, /**< 7) VSAN - Cisco MDS-specific */ + COL_CUMULATIVE_BYTES, /**< 8) Cumulative number of bytes */ + COL_CUSTOM, /**< 9) Custom column (any filter name's contents) */ + COL_DCE_CALL, /**< 10) DCE/RPC connection oriented call id OR datagram sequence number */ + COL_DCE_CTX, /**< 11) !! DEPRECATED !! - DCE/RPC connection oriented context id */ + COL_DELTA_TIME, /**< 12) Delta time */ + COL_DELTA_CONV_TIME,/**< 13) Delta time to last frame in conversation */ + COL_DELTA_TIME_DIS, /**< 14) Delta time displayed*/ + COL_RES_DST, /**< 15) Resolved dest */ + COL_UNRES_DST, /**< 16) Unresolved dest */ + COL_RES_DST_PORT, /**< 17) Resolved dest port */ + COL_UNRES_DST_PORT, /**< 18) Unresolved dest port */ + COL_DEF_DST, /**< 19) Destination address */ + COL_DEF_DST_PORT, /**< 20) Destination port */ + COL_EXPERT, /**< 21) Expert Info */ + COL_IF_DIR, /**< 22) FW-1 monitor interface/direction */ + COL_OXID, /**< 23) !! DEPRECATED !! - Fibre Channel OXID */ + COL_RXID, /**< 24) !! DEPRECATED !! - Fibre Channel RXID */ + COL_FR_DLCI, /**< 25) !! DEPRECATED !! - Frame Relay DLCI */ + COL_FREQ_CHAN, /**< 26) IEEE 802.11 (and WiMax?) - Channel */ + COL_BSSGP_TLLI, /**< 27) !! DEPRECATED !! - GPRS BSSGP IE TLLI */ + COL_HPUX_DEVID, /**< 28) !! DEPRECATED !! - HP-UX Nettl Device ID */ + COL_HPUX_SUBSYS, /**< 29) !! DEPRECATED !! - HP-UX Nettl Subsystem */ + COL_DEF_DL_DST, /**< 30) Data link layer dest address */ + COL_DEF_DL_SRC, /**< 31) Data link layer source address */ + COL_RES_DL_DST, /**< 32) Resolved DL dest */ + COL_UNRES_DL_DST, /**< 33) Unresolved DL dest */ + COL_RES_DL_SRC, /**< 34) Resolved DL source */ + COL_UNRES_DL_SRC, /**< 35) Unresolved DL source */ + COL_RSSI, /**< 36) IEEE 802.11 - received signal strength */ + COL_TX_RATE, /**< 37) IEEE 802.11 - TX rate in Mbps */ + COL_DSCP_VALUE, /**< 38) IP DSCP Value */ + COL_INFO, /**< 39) Description */ + COL_COS_VALUE, /**< 40) !! DEPRECATED !! - L2 COS Value */ + COL_RES_NET_DST, /**< 41) Resolved net dest */ + COL_UNRES_NET_DST, /**< 42) Unresolved net dest */ + COL_RES_NET_SRC, /**< 43) Resolved net source */ + COL_UNRES_NET_SRC, /**< 44) Unresolved net source */ + COL_DEF_NET_DST, /**< 45) Network layer dest address */ + COL_DEF_NET_SRC, /**< 46) Network layer source address */ + COL_NUMBER, /**< 47) Packet list item number */ + COL_PACKET_LENGTH, /**< 48) Packet length in bytes */ + COL_PROTOCOL, /**< 49) Protocol */ + COL_REL_TIME, /**< 50) Relative time */ + COL_REL_CONV_TIME, /**< 51) !! DEPRECATED !! - Relative time to beginning of conversation */ + COL_DEF_SRC, /**< 52) Source address */ + COL_DEF_SRC_PORT, /**< 53) Source port */ + COL_RES_SRC, /**< 54) Resolved source */ + COL_UNRES_SRC, /**< 55) Unresolved source */ + COL_RES_SRC_PORT, /**< 56) Resolved source port */ + COL_UNRES_SRC_PORT, /**< 57) Unresolved source port */ + COL_TEI, /**< 58) Q.921 TEI */ + COL_UTC_YMD_TIME, /**< 59) UTC date, as YYYY-MM-DD, and time */ + COL_UTC_YDOY_TIME, /**< 60) UTC date, as YYYY/DOY, and time */ + COL_UTC_TIME, /**< 61) UTC time */ + COL_CLS_TIME, /**< 62) Command line-specified time (default relative) */ + NUM_COL_FMTS /**< 63) Should always be last */ }; #ifdef __cplusplus diff --git a/epan/column-utils.c b/epan/column-utils.c index 85fb3c530f..c474d89e50 100644 --- a/epan/column-utils.c +++ b/epan/column-utils.c @@ -656,16 +656,18 @@ col_has_time_fmt(column_info *cinfo, const gint col) { return ((cinfo->fmt_matx[col][COL_CLS_TIME]) || (cinfo->fmt_matx[col][COL_ABS_TIME]) || - (cinfo->fmt_matx[col][COL_ABS_DATE_TIME]) || + (cinfo->fmt_matx[col][COL_ABS_YMD_TIME]) || + (cinfo->fmt_matx[col][COL_ABS_YDOY_TIME]) || (cinfo->fmt_matx[col][COL_UTC_TIME]) || - (cinfo->fmt_matx[col][COL_UTC_DATE_TIME]) || + (cinfo->fmt_matx[col][COL_UTC_YMD_TIME]) || + (cinfo->fmt_matx[col][COL_UTC_YDOY_TIME]) || (cinfo->fmt_matx[col][COL_REL_TIME]) || (cinfo->fmt_matx[col][COL_DELTA_TIME]) || (cinfo->fmt_matx[col][COL_DELTA_TIME_DIS])); } static void -set_abs_date_time(const frame_data *fd, gchar *buf, gboolean local) +set_abs_ymd_time(const frame_data *fd, gchar *buf, gboolean local) { struct tm *tmp; time_t then; @@ -754,9 +756,9 @@ set_abs_date_time(const frame_data *fd, gchar *buf, gboolean local) } static void -col_set_abs_date_time(const frame_data *fd, column_info *cinfo, const int col) +col_set_abs_ymd_time(const frame_data *fd, column_info *cinfo, const int col) { - set_abs_date_time(fd, cinfo->col_buf[col], TRUE); + set_abs_ymd_time(fd, cinfo->col_buf[col], TRUE); cinfo->col_expr.col_expr[col] = "frame.time"; g_strlcpy(cinfo->col_expr.col_expr_val[col],cinfo->col_buf[col],COL_MAX_LEN); @@ -764,9 +766,112 @@ col_set_abs_date_time(const frame_data *fd, column_info *cinfo, const int col) } static void -col_set_utc_date_time(const frame_data *fd, column_info *cinfo, const int col) +col_set_utc_ymd_time(const frame_data *fd, column_info *cinfo, const int col) { - set_abs_date_time(fd, cinfo->col_buf[col], FALSE); + set_abs_ymd_time(fd, cinfo->col_buf[col], FALSE); + cinfo->col_expr.col_expr[col] = "frame.time"; + g_strlcpy(cinfo->col_expr.col_expr_val[col],cinfo->col_buf[col],COL_MAX_LEN); + + cinfo->col_data[col] = cinfo->col_buf[col]; +} + +static void +set_abs_ydoy_time(const frame_data *fd, gchar *buf, gboolean local) +{ + struct tm *tmp; + time_t then; + + if (fd->flags.has_ts) { + then = fd->abs_ts.secs; + if (local) + tmp = localtime(&then); + else + tmp = gmtime(&then); + } else + tmp = NULL; + if (tmp != NULL) { + switch (timestamp_get_precision()) { + case TS_PREC_FIXED_SEC: + case TS_PREC_AUTO_SEC: + g_snprintf(buf, COL_MAX_LEN,"%04d/%03d %02d:%02d:%02d", + tmp->tm_year + 1900, + tmp->tm_yday + 1, + tmp->tm_hour, + tmp->tm_min, + tmp->tm_sec); + break; + case TS_PREC_FIXED_DSEC: + case TS_PREC_AUTO_DSEC: + g_snprintf(buf, COL_MAX_LEN,"%04d/%03d %02d:%02d:%02d.%01d", + tmp->tm_year + 1900, + tmp->tm_yday + 1, + tmp->tm_hour, + tmp->tm_min, + tmp->tm_sec, + fd->abs_ts.nsecs / 100000000); + break; + case TS_PREC_FIXED_CSEC: + case TS_PREC_AUTO_CSEC: + g_snprintf(buf, COL_MAX_LEN,"%04d/%03d %02d:%02d:%02d.%02d", + tmp->tm_year + 1900, + tmp->tm_yday + 1, + tmp->tm_hour, + tmp->tm_min, + tmp->tm_sec, + fd->abs_ts.nsecs / 10000000); + break; + case TS_PREC_FIXED_MSEC: + case TS_PREC_AUTO_MSEC: + g_snprintf(buf, COL_MAX_LEN, "%04d/%03d %02d:%02d:%02d.%03d", + tmp->tm_year + 1900, + tmp->tm_yday + 1, + tmp->tm_hour, + tmp->tm_min, + tmp->tm_sec, + fd->abs_ts.nsecs / 1000000); + break; + case TS_PREC_FIXED_USEC: + case TS_PREC_AUTO_USEC: + g_snprintf(buf, COL_MAX_LEN, "%04d/%03d %02d:%02d:%02d.%06d", + tmp->tm_year + 1900, + tmp->tm_yday + 1, + tmp->tm_hour, + tmp->tm_min, + tmp->tm_sec, + fd->abs_ts.nsecs / 1000); + break; + case TS_PREC_FIXED_NSEC: + case TS_PREC_AUTO_NSEC: + g_snprintf(buf, COL_MAX_LEN, "%04d/%03d %02d:%02d:%02d.%09d", + tmp->tm_year + 1900, + tmp->tm_yday + 1, + tmp->tm_hour, + tmp->tm_min, + tmp->tm_sec, + fd->abs_ts.nsecs); + break; + default: + g_assert_not_reached(); + } + } else { + buf[0] = '\0'; + } +} + +static void +col_set_abs_ydoy_time(const frame_data *fd, column_info *cinfo, const int col) +{ + set_abs_ydoy_time(fd, cinfo->col_buf[col], TRUE); + cinfo->col_expr.col_expr[col] = "frame.time"; + g_strlcpy(cinfo->col_expr.col_expr_val[col],cinfo->col_buf[col],COL_MAX_LEN); + + cinfo->col_data[col] = cinfo->col_buf[col]; +} + +static void +col_set_utc_ydoy_time(const frame_data *fd, column_info *cinfo, const int col) +{ + set_abs_ydoy_time(fd, cinfo->col_buf[col], FALSE); cinfo->col_expr.col_expr[col] = "frame.time"; g_strlcpy(cinfo->col_expr.col_expr_val[col],cinfo->col_buf[col],COL_MAX_LEN); @@ -1202,8 +1307,12 @@ set_fd_time(const epan_t *epan, frame_data *fd, gchar *buf) set_abs_time(fd, buf, TRUE); break; - case TS_ABSOLUTE_WITH_DATE: - set_abs_date_time(fd, buf, TRUE); + case TS_ABSOLUTE_WITH_YMD: + set_abs_ymd_time(fd, buf, TRUE); + break; + + case TS_ABSOLUTE_WITH_YDOY: + set_abs_ydoy_time(fd, buf, TRUE); break; case TS_RELATIVE: @@ -1277,8 +1386,12 @@ set_fd_time(const epan_t *epan, frame_data *fd, gchar *buf) set_abs_time(fd, buf, FALSE); break; - case TS_UTC_WITH_DATE: - set_abs_date_time(fd, buf, FALSE); + case TS_UTC_WITH_YMD: + set_abs_ymd_time(fd, buf, FALSE); + break; + + case TS_UTC_WITH_YDOY: + set_abs_ydoy_time(fd, buf, FALSE); break; case TS_NOT_SET: @@ -1296,8 +1409,12 @@ col_set_cls_time(const frame_data *fd, column_info *cinfo, const gint col) col_set_abs_time(fd, cinfo, col); break; - case TS_ABSOLUTE_WITH_DATE: - col_set_abs_date_time(fd, cinfo, col); + case TS_ABSOLUTE_WITH_YMD: + col_set_abs_ymd_time(fd, cinfo, col); + break; + + case TS_ABSOLUTE_WITH_YDOY: + col_set_abs_ydoy_time(fd, cinfo, col); break; case TS_RELATIVE: @@ -1320,8 +1437,12 @@ col_set_cls_time(const frame_data *fd, column_info *cinfo, const gint col) col_set_utc_time(fd, cinfo, col); break; - case TS_UTC_WITH_DATE: - col_set_utc_date_time(fd, cinfo, col); + case TS_UTC_WITH_YMD: + col_set_utc_ymd_time(fd, cinfo, col); + break; + + case TS_UTC_WITH_YDOY: + col_set_utc_ydoy_time(fd, cinfo, col); break; case TS_NOT_SET: @@ -1346,8 +1467,12 @@ col_set_fmt_time(const frame_data *fd, column_info *cinfo, const gint fmt, const col_set_abs_time(fd, cinfo, col); break; - case COL_ABS_DATE_TIME: - col_set_abs_date_time(fd, cinfo, col); + case COL_ABS_YMD_TIME: + col_set_abs_ymd_time(fd, cinfo, col); + break; + + case COL_ABS_YDOY_TIME: + col_set_abs_ydoy_time(fd, cinfo, col); break; case COL_REL_TIME: @@ -1366,8 +1491,12 @@ col_set_fmt_time(const frame_data *fd, column_info *cinfo, const gint fmt, const col_set_utc_time(fd, cinfo, col); break; - case COL_UTC_DATE_TIME: - col_set_utc_date_time(fd, cinfo, col); + case COL_UTC_YMD_TIME: + col_set_utc_ymd_time(fd, cinfo, col); + break; + + case COL_UTC_YDOY_TIME: + col_set_utc_ydoy_time(fd, cinfo, col); break; default: @@ -1633,9 +1762,11 @@ col_based_on_frame_data(column_info *cinfo, const gint col) case COL_NUMBER: case COL_CLS_TIME: case COL_ABS_TIME: - case COL_ABS_DATE_TIME: + case COL_ABS_YMD_TIME: + case COL_ABS_YDOY_TIME: case COL_UTC_TIME: - case COL_UTC_DATE_TIME: + case COL_UTC_YMD_TIME: + case COL_UTC_YDOY_TIME: case COL_REL_TIME: case COL_DELTA_TIME: case COL_DELTA_TIME_DIS: @@ -1659,9 +1790,11 @@ col_fill_in_frame_data(const frame_data *fd, column_info *cinfo, const gint col, case COL_CLS_TIME: case COL_ABS_TIME: - case COL_ABS_DATE_TIME: + case COL_ABS_YMD_TIME: + case COL_ABS_YDOY_TIME: case COL_UTC_TIME: - case COL_UTC_DATE_TIME: + case COL_UTC_YMD_TIME: + case COL_UTC_YDOY_TIME: case COL_REL_TIME: case COL_DELTA_TIME: case COL_DELTA_TIME_DIS: @@ -1694,9 +1827,11 @@ col_fill_in_frame_data(const frame_data *fd, column_info *cinfo, const gint col, case COL_CLS_TIME: case COL_ABS_TIME: - case COL_ABS_DATE_TIME: + case COL_ABS_YMD_TIME: + case COL_ABS_YDOY_TIME: case COL_UTC_TIME: - case COL_UTC_DATE_TIME: + case COL_UTC_YMD_TIME: + case COL_UTC_YDOY_TIME: case COL_REL_TIME: case COL_DELTA_TIME: case COL_DELTA_TIME_DIS: @@ -1729,9 +1864,11 @@ col_fill_in(packet_info *pinfo, const gboolean fill_col_exprs, const gboolean fi case COL_NUMBER: case COL_CLS_TIME: case COL_ABS_TIME: - case COL_ABS_DATE_TIME: + case COL_ABS_YMD_TIME: + case COL_ABS_YDOY_TIME: case COL_UTC_TIME: - case COL_UTC_DATE_TIME: + case COL_UTC_YMD_TIME: + case COL_UTC_YDOY_TIME: case COL_REL_TIME: case COL_DELTA_TIME: case COL_DELTA_TIME_DIS: @@ -1847,9 +1984,11 @@ col_fill_in_error(column_info *cinfo, frame_data *fdata, const gboolean fill_col case COL_NUMBER: case COL_CLS_TIME: case COL_ABS_TIME: - case COL_ABS_DATE_TIME: + case COL_ABS_YMD_TIME: + case COL_ABS_YDOY_TIME: case COL_UTC_TIME: - case COL_UTC_DATE_TIME: + case COL_UTC_YMD_TIME: + case COL_UTC_YDOY_TIME: case COL_REL_TIME: case COL_DELTA_TIME: case COL_DELTA_TIME_DIS: @@ -1918,11 +2057,13 @@ col_fill_fdata(packet_info *pinfo) case COL_NUMBER: /* frame number */ case COL_PACKET_LENGTH: /* fd->pkt_len */ case COL_CUMULATIVE_BYTES: /* fd->cum_bytes */ - case COL_CLS_TIME: + case COL_CLS_TIME: /* from times in fd structure */ case COL_ABS_TIME: - case COL_ABS_DATE_TIME: + case COL_ABS_YMD_TIME: + case COL_ABS_YDOY_TIME: case COL_UTC_TIME: - case COL_UTC_DATE_TIME: /* from fd structures */ + case COL_UTC_YMD_TIME: + case COL_UTC_YDOY_TIME: case COL_REL_TIME: case COL_DELTA_TIME: case COL_DELTA_TIME_DIS: @@ -2065,11 +2206,17 @@ col_get_text(frame_data *fd, column_info *cinfo, gint col) case COL_UTC_TIME: set_abs_time(fd, buf, FALSE); break; - case COL_ABS_DATE_TIME: - set_abs_date_time(fd, buf, TRUE); + case COL_ABS_YMD_TIME: + set_abs_ymd_time(fd, buf, TRUE); break; - case COL_UTC_DATE_TIME: - set_abs_date_time(fd, buf, FALSE); + case COL_ABS_YDOY_TIME: + set_abs_ydoy_time(fd, buf, TRUE); + break; + case COL_UTC_YMD_TIME: + set_abs_ymd_time(fd, buf, FALSE); + break; + case COL_UTC_YDOY_TIME: + set_abs_ydoy_time(fd, buf, FALSE); break; case COL_REL_TIME: set_rel_time(fd, buf); diff --git a/epan/column.c b/epan/column.c index 31d62a5a92..53e64ecc88 100644 --- a/epan/column.c +++ b/epan/column.c @@ -45,66 +45,68 @@ const gchar * col_format_to_string(const gint fmt) { static const gchar *const slist[NUM_COL_FMTS] = { "%q", /* 0) COL_8021Q_VLAN_ID */ - "%Yt", /* 1) COL_ABS_DATE_TIME */ - "%At", /* 2) COL_ABS_TIME */ - "%c", /* 3) COL_CIRCUIT_ID */ - "%Xd", /* 4) COL_DSTIDX - !! DEPRECATED !!*/ - "%Xs", /* 5) COL_SRCIDX - !! DEPRECATED !!*/ - "%V", /* 6) COL_VSAN - !! DEPRECATED !!*/ - "%B", /* 7) COL_CUMULATIVE_BYTES */ - "%Cus", /* 8) COL_CUSTOM */ - "%y", /* 9) COL_DCE_CALL */ - "%z", /* 10) COL_DCE_CTX */ - "%Tt", /* 11) COL_DELTA_TIME */ - "%dct", /* 12) COL_DELTA_CONV_TIME */ - "%Gt", /* 13) COL_DELTA_TIME_DIS */ - "%rd", /* 14) COL_RES_DST */ - "%ud", /* 15) COL_UNRES_DST */ - "%rD", /* 16) COL_RES_DST_PORT */ - "%uD", /* 17) COL_UNRES_DST_PORT */ - "%d", /* 18) COL_DEF_DST */ - "%D", /* 19) COL_DEF_DST_PORT */ - "%a", /* 20) COL_EXPERT */ - "%I", /* 21) COL_IF_DIR */ - "%XO", /* 22) COL_OXID */ - "%XR", /* 23) COL_RXID */ - "%C", /* 24) !! DEPRECATED !! - COL_FR_DLCI */ - "%F", /* 25) COL_FREQ_CHAN */ - "%l", /* 26) !! DEPRECATED !! - COL_BSSGP_TLLI */ - "%P", /* 27) !! DEPRECATED !! - COL_HPUX_DEVID */ - "%H", /* 28) !! DEPRECATED !! - COL_HPUX_SUBSYS */ - "%hd", /* 29) COL_DEF_DL_DST */ - "%hs", /* 30) COL_DEF_DL_SRC */ - "%rhd", /* 31) COL_RES_DL_DST */ - "%uhd", /* 32) COL_UNRES_DL_DST */ - "%rhs", /* 33) COL_RES_DL_SRC*/ - "%uhs", /* 34) COL_UNRES_DL_SRC */ - "%e", /* 35) COL_RSSI */ - "%x", /* 36) COL_TX_RATE */ - "%f", /* 37) COL_DSCP_VALUE */ - "%i", /* 38) COL_INFO */ - "%U", /* 39) !! DEPRECATED !! - COL_COS_VALUE */ - "%rnd", /* 40) COL_RES_NET_DST */ - "%und", /* 41) COL_UNRES_NET_DST */ - "%rns", /* 42) COL_RES_NET_SRC */ - "%uns", /* 43) COL_UNRES_NET_SRC */ - "%nd", /* 44) COL_DEF_NET_DST */ - "%ns", /* 45) COL_DEF_NET_SRC */ - "%m", /* 46) COL_NUMBER */ - "%L", /* 47) COL_PACKET_LENGTH */ - "%p", /* 48) COL_PROTOCOL */ - "%Rt", /* 49) COL_REL_TIME */ - "%rct", /* 50) !! DEPRECATED !! - COL_REL_CONV_TIME */ - "%s", /* 51) COL_DEF_SRC */ - "%S", /* 52) COL_DEF_SRC_PORT */ - "%rs", /* 53) COL_RES_SRC */ - "%us", /* 54) COL_UNRES_SRC */ - "%rS", /* 55) COL_RES_SRC_PORT */ - "%uS", /* 56) COL_UNRES_SRC_PORT */ - "%E", /* 57) COL_TEI */ - "%Yut", /* 58) COL_UTC_DATE_TIME */ - "%Aut", /* 59) COL_UTC_TIME */ - "%t" /* 60) COL_CLS_TIME */ + "%Yt", /* 1) COL_ABS_YMD_TIME */ + "%YDOYt", /* 2) COL_ABS_YDOY_TIME */ + "%At", /* 3) COL_ABS_TIME */ + "%c", /* 4) COL_CIRCUIT_ID */ + "%Xd", /* 5) COL_DSTIDX - !! DEPRECATED !!*/ + "%Xs", /* 6) COL_SRCIDX - !! DEPRECATED !!*/ + "%V", /* 7) COL_VSAN - !! DEPRECATED !!*/ + "%B", /* 8) COL_CUMULATIVE_BYTES */ + "%Cus", /* 9) COL_CUSTOM */ + "%y", /* 10) COL_DCE_CALL */ + "%z", /* 11) COL_DCE_CTX */ + "%Tt", /* 12) COL_DELTA_TIME */ + "%dct", /* 13) COL_DELTA_CONV_TIME */ + "%Gt", /* 14) COL_DELTA_TIME_DIS */ + "%rd", /* 15) COL_RES_DST */ + "%ud", /* 16) COL_UNRES_DST */ + "%rD", /* 17) COL_RES_DST_PORT */ + "%uD", /* 18) COL_UNRES_DST_PORT */ + "%d", /* 19) COL_DEF_DST */ + "%D", /* 20) COL_DEF_DST_PORT */ + "%a", /* 21) COL_EXPERT */ + "%I", /* 22) COL_IF_DIR */ + "%XO", /* 23) COL_OXID */ + "%XR", /* 24) COL_RXID */ + "%C", /* 25) !! DEPRECATED !! - COL_FR_DLCI */ + "%F", /* 26) COL_FREQ_CHAN */ + "%l", /* 27) !! DEPRECATED !! - COL_BSSGP_TLLI */ + "%P", /* 28) !! DEPRECATED !! - COL_HPUX_DEVID */ + "%H", /* 29) !! DEPRECATED !! - COL_HPUX_SUBSYS */ + "%hd", /* 30) COL_DEF_DL_DST */ + "%hs", /* 31) COL_DEF_DL_SRC */ + "%rhd", /* 32) COL_RES_DL_DST */ + "%uhd", /* 33) COL_UNRES_DL_DST */ + "%rhs", /* 34) COL_RES_DL_SRC*/ + "%uhs", /* 35) COL_UNRES_DL_SRC */ + "%e", /* 36) COL_RSSI */ + "%x", /* 37) COL_TX_RATE */ + "%f", /* 38) COL_DSCP_VALUE */ + "%i", /* 39) COL_INFO */ + "%U", /* 40) !! DEPRECATED !! - COL_COS_VALUE */ + "%rnd", /* 41) COL_RES_NET_DST */ + "%und", /* 42) COL_UNRES_NET_DST */ + "%rns", /* 43) COL_RES_NET_SRC */ + "%uns", /* 44) COL_UNRES_NET_SRC */ + "%nd", /* 45) COL_DEF_NET_DST */ + "%ns", /* 46) COL_DEF_NET_SRC */ + "%m", /* 47) COL_NUMBER */ + "%L", /* 48) COL_PACKET_LENGTH */ + "%p", /* 49) COL_PROTOCOL */ + "%Rt", /* 50) COL_REL_TIME */ + "%rct", /* 51) !! DEPRECATED !! - COL_REL_CONV_TIME */ + "%s", /* 52) COL_DEF_SRC */ + "%S", /* 53) COL_DEF_SRC_PORT */ + "%rs", /* 54) COL_RES_SRC */ + "%us", /* 55) COL_UNRES_SRC */ + "%rS", /* 56) COL_RES_SRC_PORT */ + "%uS", /* 57) COL_UNRES_SRC_PORT */ + "%E", /* 58) COL_TEI */ + "%Yut", /* 59) COL_UTC_YMD_TIME */ + "%YDOYut", /* 60) COL_UTC_YDOY_TIME */ + "%Aut", /* 61) COL_UTC_TIME */ + "%t" /* 62) COL_CLS_TIME */ }; if (fmt < 0 || fmt >= NUM_COL_FMTS) @@ -119,66 +121,68 @@ const gchar * col_format_desc(const gint fmt) { static const gchar *const dlist[NUM_COL_FMTS] = { "802.1Q VLAN id", /* 0) COL_8021Q_VLAN_ID */ - "Absolute date and time", /* 1) COL_ABS_DATE_TIME */ - "Absolute time", /* 2) COL_ABS_TIME */ - "Circuit ID", /* 3) COL_CIRCUIT_ID */ - "Cisco Dst PortIdx", /* 4) COL_DSTIDX */ - "Cisco Src PortIdx", /* 5) COL_SRCIDX */ - "Cisco VSAN", /* 6) COL_VSAN */ - "Cumulative Bytes" , /* 7) COL_CUMULATIVE_BYTES */ - "Custom", /* 8) COL_CUSTOM */ - "DCE/RPC call (cn_call_id / dg_seqnum)", /* 9) COL_DCE_CALL */ - "DCE/RPC context ID (cn_ctx_id)", /* 10) COL_DCE_CTX */ - "Delta time", /* 11) COL_DELTA_TIME */ - "Delta time (conversation)", /* 12) COL_DELTA_CONV_TIME */ - "Delta time displayed", /* 13) COL_DELTA_TIME_DIS */ - "Dest addr (resolved)", /* 14) COL_RES_DST */ - "Dest addr (unresolved)", /* 15) COL_UNRES_DST */ - "Dest port (resolved)", /* 16) COL_RES_DST_PORT */ - "Dest port (unresolved)", /* 17) COL_UNRES_DST_PORT */ - "Destination address", /* 18) COL_DEF_DST */ - "Destination port", /* 19) COL_DEF_DST_PORT */ - "Expert Info Severity", /* 20) COL_EXPERT */ - "FW-1 monitor if/direction", /* 21) COL_IF_DIR */ - "Fibre Channel OXID", /* 22) COL_OXID */ - "Fibre Channel RXID", /* 23) COL_RXID */ - "Frame Relay DLCI", /* 24) !! DEPRECATED !! - COL_FR_DLCI */ - "Frequency/Channel", /* 25) COL_FREQ_CHAN */ - "GPRS BSSGP TLLI", /* 26) !! DEPRECATED !! - COL_BSSGP_TLLI */ - "HP-UX Device ID", /* 27) !! DEPRECATED !! - COL_HPUX_DEVID */ - "HP-UX Subsystem", /* 28) !! DEPRECATED !! - COL_HPUX_SUBSYS */ - "Hardware dest addr", /* 29) COL_DEF_DL_DST */ - "Hardware src addr", /* 30) COL_DEF_DL_SRC */ - "Hw dest addr (resolved)", /* 31) COL_RES_DL_DST */ - "Hw dest addr (unresolved)", /* 32) COL_UNRES_DL_DST */ - "Hw src addr (resolved)", /* 33) COL_RES_DL_SRC*/ - "Hw src addr (unresolved)", /* 34) COL_UNRES_DL_SRC */ - "IEEE 802.11 RSSI", /* 35) COL_RSSI */ - "IEEE 802.11 TX rate", /* 36) COL_TX_RATE */ - "IP DSCP Value", /* 37) COL_DSCP_VALUE */ - "Information", /* 38) COL_INFO */ - "L2 COS Value (802.1p)", /* 39) !! DEPRECATED !! - COL_COS_VALUE */ - "Net dest addr (resolved)", /* 40) COL_RES_NET_DST */ - "Net dest addr (unresolved)", /* 41) COL_UNRES_NET_DST */ - "Net src addr (resolved)", /* 42) COL_RES_NET_SRC */ - "Net src addr (unresolved)", /* 43) COL_UNRES_NET_SRC */ - "Network dest addr", /* 44) COL_DEF_NET_DST */ - "Network src addr", /* 45) COL_DEF_NET_SRC */ - "Number", /* 46) COL_NUMBER */ - "Packet length (bytes)" , /* 47) COL_PACKET_LENGTH */ - "Protocol", /* 48) COL_PROTOCOL */ - "Relative time", /* 49) COL_REL_TIME */ - "Relative time (conversation)", /* 50) !! DEPRECATED !! - COL_REL_CONV_TIME */ - "Source address", /* 51) COL_DEF_SRC */ - "Source port", /* 52) COL_DEF_SRC_PORT */ - "Src addr (resolved)", /* 53) COL_RES_SRC */ - "Src addr (unresolved)", /* 54) COL_UNRES_SRC */ - "Src port (resolved)", /* 55) COL_RES_SRC_PORT */ - "Src port (unresolved)", /* 56) COL_UNRES_SRC_PORT */ - "TEI", /* 57) COL_TEI */ - "UTC date and time", /* 58) COL_UTC_DATE_TIME */ - "UTC time", /* 59) COL_UTC_TIME */ - "Time (format as specified)" /* 60) COL_CLS_TIME */ + "Absolute date, as YYYY-MM-DD, and time", /* 1) COL_ABS_YMD_TIME */ + "Absolute date, as YYYY/DOY, and time", /* 2) COL_ABS_YDOY_TIME */ + "Absolute time", /* 3) COL_ABS_TIME */ + "Circuit ID", /* 4) COL_CIRCUIT_ID */ + "Cisco Dst PortIdx", /* 5) COL_DSTIDX */ + "Cisco Src PortIdx", /* 6) COL_SRCIDX */ + "Cisco VSAN", /* 7) COL_VSAN */ + "Cumulative Bytes" , /* 8) COL_CUMULATIVE_BYTES */ + "Custom", /* 9) COL_CUSTOM */ + "DCE/RPC call (cn_call_id / dg_seqnum)", /* 10) COL_DCE_CALL */ + "DCE/RPC context ID (cn_ctx_id)", /* 11) COL_DCE_CTX */ + "Delta time", /* 12) COL_DELTA_TIME */ + "Delta time (conversation)", /* 13) COL_DELTA_CONV_TIME */ + "Delta time displayed", /* 14) COL_DELTA_TIME_DIS */ + "Dest addr (resolved)", /* 15) COL_RES_DST */ + "Dest addr (unresolved)", /* 16) COL_UNRES_DST */ + "Dest port (resolved)", /* 17) COL_RES_DST_PORT */ + "Dest port (unresolved)", /* 18) COL_UNRES_DST_PORT */ + "Destination address", /* 19) COL_DEF_DST */ + "Destination port", /* 20) COL_DEF_DST_PORT */ + "Expert Info Severity", /* 21) COL_EXPERT */ + "FW-1 monitor if/direction", /* 22) COL_IF_DIR */ + "Fibre Channel OXID", /* 23) COL_OXID */ + "Fibre Channel RXID", /* 24) COL_RXID */ + "Frame Relay DLCI", /* 25) !! DEPRECATED !! - COL_FR_DLCI */ + "Frequency/Channel", /* 26) COL_FREQ_CHAN */ + "GPRS BSSGP TLLI", /* 27) !! DEPRECATED !! - COL_BSSGP_TLLI */ + "HP-UX Device ID", /* 28) !! DEPRECATED !! - COL_HPUX_DEVID */ + "HP-UX Subsystem", /* 29) !! DEPRECATED !! - COL_HPUX_SUBSYS */ + "Hardware dest addr", /* 30) COL_DEF_DL_DST */ + "Hardware src addr", /* 31) COL_DEF_DL_SRC */ + "Hw dest addr (resolved)", /* 32) COL_RES_DL_DST */ + "Hw dest addr (unresolved)", /* 33) COL_UNRES_DL_DST */ + "Hw src addr (resolved)", /* 34) COL_RES_DL_SRC*/ + "Hw src addr (unresolved)", /* 35) COL_UNRES_DL_SRC */ + "IEEE 802.11 RSSI", /* 36) COL_RSSI */ + "IEEE 802.11 TX rate", /* 37) COL_TX_RATE */ + "IP DSCP Value", /* 38) COL_DSCP_VALUE */ + "Information", /* 39) COL_INFO */ + "L2 COS Value (802.1p)", /* 40) !! DEPRECATED !! - COL_COS_VALUE */ + "Net dest addr (resolved)", /* 41) COL_RES_NET_DST */ + "Net dest addr (unresolved)", /* 42) COL_UNRES_NET_DST */ + "Net src addr (resolved)", /* 43) COL_RES_NET_SRC */ + "Net src addr (unresolved)", /* 44) COL_UNRES_NET_SRC */ + "Network dest addr", /* 45) COL_DEF_NET_DST */ + "Network src addr", /* 46) COL_DEF_NET_SRC */ + "Number", /* 47) COL_NUMBER */ + "Packet length (bytes)" , /* 48) COL_PACKET_LENGTH */ + "Protocol", /* 49) COL_PROTOCOL */ + "Relative time", /* 50) COL_REL_TIME */ + "Relative time (conversation)", /* 51) !! DEPRECATED !! - COL_REL_CONV_TIME */ + "Source address", /* 52) COL_DEF_SRC */ + "Source port", /* 53) COL_DEF_SRC_PORT */ + "Src addr (resolved)", /* 54) COL_RES_SRC */ + "Src addr (unresolved)", /* 55) COL_UNRES_SRC */ + "Src port (resolved)", /* 56) COL_RES_SRC_PORT */ + "Src port (unresolved)", /* 57) COL_UNRES_SRC_PORT */ + "TEI", /* 58) COL_TEI */ + "UTC date, as YYYY-MM-DD, and time", /* 59) COL_UTC_YMD_TIME */ + "UTC date, as YYYY/DOY, and time", /* 60) COL_UTC_YDOY_TIME */ + "UTC time", /* 61) COL_UTC_TIME */ + "Time (format as specified)" /* 62) COL_CLS_TIME */ }; g_assert((fmt >= 0) && (fmt < NUM_COL_FMTS)); @@ -281,8 +285,8 @@ get_timestamp_column_longest_string(const gint type, const gint precision) { switch(type) { - case(TS_ABSOLUTE_WITH_DATE): - case(TS_UTC_WITH_DATE): + case(TS_ABSOLUTE_WITH_YMD): + case(TS_UTC_WITH_YMD): switch(precision) { case(TS_PREC_AUTO_SEC): case(TS_PREC_FIXED_SEC): @@ -312,6 +316,37 @@ get_timestamp_column_longest_string(const gint type, const gint precision) g_assert_not_reached(); } break; + case(TS_ABSOLUTE_WITH_YDOY): + case(TS_UTC_WITH_YDOY): + switch(precision) { + case(TS_PREC_AUTO_SEC): + case(TS_PREC_FIXED_SEC): + return "0000/000 00:00:00"; + break; + case(TS_PREC_AUTO_DSEC): + case(TS_PREC_FIXED_DSEC): + return "0000/000 00:00:00.0"; + break; + case(TS_PREC_AUTO_CSEC): + case(TS_PREC_FIXED_CSEC): + return "0000/000 00:00:00.00"; + break; + case(TS_PREC_AUTO_MSEC): + case(TS_PREC_FIXED_MSEC): + return "0000/000 00:00:00.000"; + break; + case(TS_PREC_AUTO_USEC): + case(TS_PREC_FIXED_USEC): + return "0000/000 00:00:00.000000"; + break; + case(TS_PREC_AUTO_NSEC): + case(TS_PREC_FIXED_NSEC): + return "0000/000 00:00:00.000000000"; + break; + default: + g_assert_not_reached(); + } + break; case(TS_ABSOLUTE): case(TS_UTC): switch(precision) { @@ -451,11 +486,17 @@ get_column_longest_string(const gint format) case COL_CLS_TIME: return get_timestamp_column_longest_string(timestamp_get_type(), timestamp_get_precision()); break; - case COL_ABS_DATE_TIME: - return get_timestamp_column_longest_string(TS_ABSOLUTE_WITH_DATE, timestamp_get_precision()); + case COL_ABS_YMD_TIME: + return get_timestamp_column_longest_string(TS_ABSOLUTE_WITH_YMD, timestamp_get_precision()); break; - case COL_UTC_DATE_TIME: - return get_timestamp_column_longest_string(TS_UTC_WITH_DATE, timestamp_get_precision()); + case COL_ABS_YDOY_TIME: + return get_timestamp_column_longest_string(TS_ABSOLUTE_WITH_YDOY, timestamp_get_precision()); + break; + case COL_UTC_YMD_TIME: + return get_timestamp_column_longest_string(TS_UTC_WITH_YMD, timestamp_get_precision()); + break; + case COL_UTC_YDOY_TIME: + return get_timestamp_column_longest_string(TS_UTC_WITH_YDOY, timestamp_get_precision()); break; case COL_ABS_TIME: return get_timestamp_column_longest_string(TS_ABSOLUTE, timestamp_get_precision()); diff --git a/epan/frame_data.c b/epan/frame_data.c index ec25b3407d..e1e501af74 100644 --- a/epan/frame_data.c +++ b/epan/frame_data.c @@ -212,9 +212,11 @@ frame_data_compare(const struct epan_session *epan, const frame_data *fdata1, co case COL_CLS_TIME: switch (timestamp_get_type()) { case TS_ABSOLUTE: - case TS_ABSOLUTE_WITH_DATE: + case TS_ABSOLUTE_WITH_YMD: + case TS_ABSOLUTE_WITH_YDOY: case TS_UTC: - case TS_UTC_WITH_DATE: + case TS_UTC_WITH_YMD: + case TS_UTC_WITH_YDOY: case TS_EPOCH: return COMPARE_TS(abs_ts); @@ -233,9 +235,11 @@ frame_data_compare(const struct epan_session *epan, const frame_data *fdata1, co return 0; case COL_ABS_TIME: - case COL_ABS_DATE_TIME: + case COL_ABS_YMD_TIME: + case COL_ABS_YDOY_TIME: case COL_UTC_TIME: - case COL_UTC_DATE_TIME: + case COL_UTC_YMD_TIME: + case COL_UTC_YDOY_TIME: return COMPARE_TS(abs_ts); case COL_REL_TIME: diff --git a/epan/timestamp.h b/epan/timestamp.h index 0992b3eaa0..9d90e6d2b4 100644 --- a/epan/timestamp.h +++ b/epan/timestamp.h @@ -36,13 +36,15 @@ extern "C" { */ typedef enum { TS_RELATIVE, /* Since start of capture */ - TS_ABSOLUTE, - TS_ABSOLUTE_WITH_DATE, + TS_ABSOLUTE, /* Local absolute time, without date */ + TS_ABSOLUTE_WITH_YMD, /* Local absolute time, with date in YYYY-MM-DD form */ + TS_ABSOLUTE_WITH_YDOY, /* Local absolute time, with date in YYYY DOY form */ TS_DELTA, /* Since previous captured packet */ TS_DELTA_DIS, /* Since previous displayed packet */ TS_EPOCH, /* Seconds (and fractions) since epoch */ - TS_UTC, - TS_UTC_WITH_DATE, + TS_UTC, /* UTC absolute time, without date */ + TS_UTC_WITH_YMD, /* UTC absolute time, with date in YYYY-MM-DD form */ + TS_UTC_WITH_YDOY, /* UTC absolute time, with date in YYYY DOY form */ /* * Special value used for the command-line setting in Wireshark, to indicate diff --git a/epan/wslua/wslua_pinfo.c b/epan/wslua/wslua_pinfo.c index 7a5782861b..70aa79a8b5 100644 --- a/epan/wslua/wslua_pinfo.c +++ b/epan/wslua/wslua_pinfo.c @@ -542,8 +542,10 @@ static const struct col_names_t colnames[] = { {"utc_time",COL_UTC_TIME}, {"cls_time",COL_CLS_TIME}, {"rel_time",COL_REL_TIME}, - {"date",COL_ABS_DATE_TIME}, - {"utc_date",COL_UTC_DATE_TIME}, + {"date",COL_ABS_YMD_TIME}, + {"date_doy",COL_ABS_YDOY_TIME}, + {"utc_date",COL_UTC_YMD_TIME}, + {"utc_date_doy",COL_UTC_YDOY_TIME}, {"delta_time",COL_DELTA_TIME}, {"delta_time_displayed",COL_DELTA_TIME_DIS}, {"src",COL_DEF_SRC}, diff --git a/rawshark.c b/rawshark.c index a2825fdc1e..8e762b625f 100644 --- a/rawshark.c +++ b/rawshark.c @@ -712,7 +712,9 @@ main(int argc, char *argv[]) else if (strcmp(optarg, "a") == 0) timestamp_set_type(TS_ABSOLUTE); else if (strcmp(optarg, "ad") == 0) - timestamp_set_type(TS_ABSOLUTE_WITH_DATE); + timestamp_set_type(TS_ABSOLUTE_WITH_YMD); + else if (strcmp(optarg, "adoy") == 0) + timestamp_set_type(TS_ABSOLUTE_WITH_YDOY); else if (strcmp(optarg, "d") == 0) timestamp_set_type(TS_DELTA); else if (strcmp(optarg, "dd") == 0) @@ -722,12 +724,22 @@ main(int argc, char *argv[]) else if (strcmp(optarg, "u") == 0) timestamp_set_type(TS_UTC); else if (strcmp(optarg, "ud") == 0) - timestamp_set_type(TS_UTC_WITH_DATE); + timestamp_set_type(TS_UTC_WITH_YMD); + else if (strcmp(optarg, "udoy") == 0) + timestamp_set_type(TS_UTC_WITH_YDOY); else { cmdarg_err("Invalid time stamp type \"%s\"", optarg); - cmdarg_err_cont("It must be \"r\" for relative, \"a\" for absolute,"); - cmdarg_err_cont("\"ad\" for absolute with date, or \"d\" for delta."); + cmdarg_err_cont( +"It must be \"a\" for absolute, \"ad\" for absolute with YYYY-MM-DD date,"); + cmdarg_err_cont( +"\"adoy\" for absolute with YYYY/DOY date, \"d\" for delta,"); + cmdarg_err_cont( +"\"dd\" for delta displayed, \"e\" for epoch, \"r\" for relative,"); + cmdarg_err_cont( +"\"u\" for absolute UTC, \"ud\" for absolute UTC with YYYY-MM-DD date,"); + cmdarg_err_cont( +"or \"udoy\" for absolute UTC with YYYY/DOY date."); exit(1); } break; diff --git a/tshark.c b/tshark.c index 0f82a52c67..db098fa994 100644 --- a/tshark.c +++ b/tshark.c @@ -1424,7 +1424,9 @@ main(int argc, char *argv[]) else if (strcmp(optarg, "a") == 0) timestamp_set_type(TS_ABSOLUTE); else if (strcmp(optarg, "ad") == 0) - timestamp_set_type(TS_ABSOLUTE_WITH_DATE); + timestamp_set_type(TS_ABSOLUTE_WITH_YMD); + else if (strcmp(optarg, "adoy") == 0) + timestamp_set_type(TS_ABSOLUTE_WITH_YDOY); else if (strcmp(optarg, "d") == 0) timestamp_set_type(TS_DELTA); else if (strcmp(optarg, "dd") == 0) @@ -1434,13 +1436,21 @@ main(int argc, char *argv[]) else if (strcmp(optarg, "u") == 0) timestamp_set_type(TS_UTC); else if (strcmp(optarg, "ud") == 0) - timestamp_set_type(TS_UTC_WITH_DATE); + timestamp_set_type(TS_UTC_WITH_YMD); + else if (strcmp(optarg, "udoy") == 0) + timestamp_set_type(TS_UTC_WITH_YDOY); else { - cmdarg_err("Invalid time stamp type \"%s\"", - optarg); - cmdarg_err_cont("It must be \"a\" for absolute, \"ad\" for absolute with date, \"d\" for delta,"); - cmdarg_err_cont("\"dd\" for delta displayed, \"e\" for epoch, \"r\" for relative, \"u\" for UTC, "); - cmdarg_err_cont("or \"ud\" for UTC with date."); + cmdarg_err("Invalid time stamp type \"%s\"", optarg); + cmdarg_err_cont( +"It must be \"a\" for absolute, \"ad\" for absolute with YYYY-MM-DD date,"); + cmdarg_err_cont( +"\"adoy\" for absolute with YYYY/DOY date, \"d\" for delta,"); + cmdarg_err_cont( +"\"dd\" for delta displayed, \"e\" for epoch, \"r\" for relative,"); + cmdarg_err_cont( +"\"u\" for absolute UTC, \"ud\" for absolute UTC with YYYY-MM-DD date,"); + cmdarg_err_cont( +"or \"udoy\" for absolute UTC with YYYY/DOY date."); return 1; } break; @@ -3552,9 +3562,11 @@ print_columns(capture_file *cf) case COL_CLS_TIME: case COL_REL_TIME: case COL_ABS_TIME: - case COL_ABS_DATE_TIME: + case COL_ABS_YMD_TIME: /* XXX - wider */ + case COL_ABS_YDOY_TIME: /* XXX - wider */ case COL_UTC_TIME: - case COL_UTC_DATE_TIME: /* XXX - wider */ + case COL_UTC_YMD_TIME: /* XXX - wider */ + case COL_UTC_YDOY_TIME: /* XXX - wider */ column_len = col_len = strlen(cf->cinfo.col_data[i]); if (column_len < 10) column_len = 10; diff --git a/ui/cli/tap-iostat.c b/ui/cli/tap-iostat.c index b6835946bd..4c98582103 100644 --- a/ui/cli/tap-iostat.c +++ b/ui/cli/tap-iostat.c @@ -630,11 +630,19 @@ iostat_draw(void *arg) else invl_col_w = (2*dur_mag) + (2*invl_prec) + 10; - /* Update the width of the time interval column for "-t ad" */ - if (timestamp_get_type()==TS_ABSOLUTE_WITH_DATE) + /* Update the width of the time interval column if date is shown */ + switch (timestamp_get_type()) { + case TS_ABSOLUTE_WITH_YMD: + case TS_ABSOLUTE_WITH_YDOY: + case TS_UTC_WITH_YMD: + case TS_UTC_WITH_YDOY: invl_col_w = MAX(invl_col_w, 23); - else + break; + + default: invl_col_w = MAX(invl_col_w, 12); + break; + } borderlen = MAX(borderlen, invl_col_w); @@ -898,7 +906,10 @@ iostat_draw(void *arg) case TS_ABSOLUTE: printf("\n| Time "); break; - case TS_ABSOLUTE_WITH_DATE: + case TS_ABSOLUTE_WITH_YMD: + case TS_ABSOLUTE_WITH_YDOY: + case TS_UTC_WITH_YMD: + case TS_UTC_WITH_YDOY: printf("\n| Date and time"); k = 16; break; @@ -973,18 +984,19 @@ iostat_draw(void *arg) /* Patch for Absolute Time */ /* XXX - has a Y2.038K problem with 32-bit time_t */ the_time = (time_t)(iot->start_time + (t/1000000ULL)); - tm_time = localtime(&the_time); /* Display the interval for this row */ switch (timestamp_get_type()) { case TS_ABSOLUTE: + tm_time = localtime(&the_time); printf("| %02d:%02d:%02d |", tm_time->tm_hour, tm_time->tm_min, tm_time->tm_sec); break; - case TS_ABSOLUTE_WITH_DATE: + case TS_ABSOLUTE_WITH_YMD: + tm_time = localtime(&the_time); printf("| %04d-%02d-%02d %02d:%02d:%02d |", tm_time->tm_year + 1900, tm_time->tm_mon + 1, @@ -994,9 +1006,47 @@ iostat_draw(void *arg) tm_time->tm_sec); break; + case TS_ABSOLUTE_WITH_YDOY: + tm_time = localtime(&the_time); + printf("| %04d/%03d %02d:%02d:%02d |", + tm_time->tm_year + 1900, + tm_time->tm_yday + 1, + tm_time->tm_hour, + tm_time->tm_min, + tm_time->tm_sec); + break; + + case TS_UTC: + tm_time = gmtime(&the_time); + printf("| %02d:%02d:%02d |", + tm_time->tm_hour, + tm_time->tm_min, + tm_time->tm_sec); + break; + + case TS_UTC_WITH_YMD: + tm_time = gmtime(&the_time); + printf("| %04d-%02d-%02d %02d:%02d:%02d |", + tm_time->tm_year + 1900, + tm_time->tm_mon + 1, + tm_time->tm_mday, + tm_time->tm_hour, + tm_time->tm_min, + tm_time->tm_sec); + break; + + case TS_UTC_WITH_YDOY: + tm_time = gmtime(&the_time); + printf("| %04d/%03d %02d:%02d:%02d |", + tm_time->tm_year + 1900, + tm_time->tm_yday + 1, + tm_time->tm_hour, + tm_time->tm_min, + tm_time->tm_sec); + break; + case TS_RELATIVE: case TS_NOT_SET: - if (invl_prec==0) { if(last_row) { int maxw; @@ -1021,8 +1071,6 @@ iostat_draw(void *arg) /* case TS_DELTA: case TS_DELTA_DIS: case TS_EPOCH: - case TS_UTC: - case TS_UTC_WITH_DATE: are not implemented */ default: break; @@ -1337,9 +1385,7 @@ iostat_init(const char *opt_arg, void* userdata _U_) case TS_DELTA: case TS_DELTA_DIS: case TS_EPOCH: - case TS_UTC: - case TS_UTC_WITH_DATE: - fprintf(stderr, "\ntshark: invalid -t operand. io,stat only supports -t \n"); + fprintf(stderr, "\ntshark: invalid -t operand. io,stat only supports -t \n"); exit(1); default: break; diff --git a/ui/cli/tap-iousers.c b/ui/cli/tap-iousers.c index b51d708e59..e1bac1f0ac 100644 --- a/ui/cli/tap-iousers.c +++ b/ui/cli/tap-iousers.c @@ -373,10 +373,14 @@ iousers_draw(void *arg) switch (timestamp_get_type()) { case TS_ABSOLUTE: + case TS_UTC: printf(" | <- | | -> | | Total | Absolute Time | Duration |\n"); printf(" | Frames Bytes | | Frames Bytes | | Frames Bytes | Start | |\n"); break; - case TS_ABSOLUTE_WITH_DATE: + case TS_ABSOLUTE_WITH_YMD: + case TS_ABSOLUTE_WITH_YDOY: + case TS_UTC_WITH_YMD: + case TS_UTC_WITH_YDOY: printf(" | <- | | -> | | Total | Absolute Date | Duration |\n"); printf(" | Frames Bytes | | Frames Bytes | | Frames Bytes | Start | |\n"); break; @@ -413,16 +417,17 @@ iousers_draw(void *arg) iui->bytes1+iui->bytes2 ); - tm_time = localtime(&iui->start_abs_time.secs); switch (timestamp_get_type()) { case TS_ABSOLUTE: + tm_time = localtime(&iui->start_abs_time.secs); printf("%02d:%02d:%02d %12.4f\n", tm_time->tm_hour, tm_time->tm_min, tm_time->tm_sec, nstime_to_sec(&iui->stop_rel_time) - nstime_to_sec(&iui->start_rel_time)); break; - case TS_ABSOLUTE_WITH_DATE: + case TS_ABSOLUTE_WITH_YMD: + tm_time = localtime(&iui->start_abs_time.secs); printf("%04d-%02d-%02d %02d:%02d:%02d %12.4f\n", tm_time->tm_year + 1900, tm_time->tm_mon + 1, @@ -432,6 +437,45 @@ iousers_draw(void *arg) tm_time->tm_sec, nstime_to_sec(&iui->stop_rel_time) - nstime_to_sec(&iui->start_rel_time)); break; + case TS_ABSOLUTE_WITH_YDOY: + tm_time = localtime(&iui->start_abs_time.secs); + printf("%04d/%03d %02d:%02d:%02d %12.4f\n", + tm_time->tm_year + 1900, + tm_time->tm_yday + 1, + tm_time->tm_hour, + tm_time->tm_min, + tm_time->tm_sec, + nstime_to_sec(&iui->stop_rel_time) - nstime_to_sec(&iui->start_rel_time)); + break; + case TS_UTC: + tm_time = gmtime(&iui->start_abs_time.secs); + printf("%02d:%02d:%02d %12.4f\n", + tm_time->tm_hour, + tm_time->tm_min, + tm_time->tm_sec, + nstime_to_sec(&iui->stop_rel_time) - nstime_to_sec(&iui->start_rel_time)); + break; + case TS_UTC_WITH_YMD: + tm_time = gmtime(&iui->start_abs_time.secs); + printf("%04d-%02d-%02d %02d:%02d:%02d %12.4f\n", + tm_time->tm_year + 1900, + tm_time->tm_mon + 1, + tm_time->tm_mday, + tm_time->tm_hour, + tm_time->tm_min, + tm_time->tm_sec, + nstime_to_sec(&iui->stop_rel_time) - nstime_to_sec(&iui->start_rel_time)); + break; + case TS_UTC_WITH_YDOY: + tm_time = gmtime(&iui->start_abs_time.secs); + printf("%04d/%03d %02d:%02d:%02d %12.4f\n", + tm_time->tm_year + 1900, + tm_time->tm_yday + 1, + tm_time->tm_hour, + tm_time->tm_min, + tm_time->tm_sec, + nstime_to_sec(&iui->stop_rel_time) - nstime_to_sec(&iui->start_rel_time)); + break; case TS_RELATIVE: case TS_NOT_SET: default: diff --git a/ui/gtk/main.c b/ui/gtk/main.c index bad98e4873..8111264da1 100644 --- a/ui/gtk/main.c +++ b/ui/gtk/main.c @@ -2712,7 +2712,9 @@ main(int argc, char *argv[]) else if (strcmp(optarg, "a") == 0) timestamp_set_type(TS_ABSOLUTE); else if (strcmp(optarg, "ad") == 0) - timestamp_set_type(TS_ABSOLUTE_WITH_DATE); + timestamp_set_type(TS_ABSOLUTE_WITH_YMD); + else if (strcmp(optarg, "adoy") == 0) + timestamp_set_type(TS_ABSOLUTE_WITH_YDOY); else if (strcmp(optarg, "d") == 0) timestamp_set_type(TS_DELTA); else if (strcmp(optarg, "dd") == 0) @@ -2722,12 +2724,21 @@ main(int argc, char *argv[]) else if (strcmp(optarg, "u") == 0) timestamp_set_type(TS_UTC); else if (strcmp(optarg, "ud") == 0) - timestamp_set_type(TS_UTC_WITH_DATE); + timestamp_set_type(TS_UTC_WITH_YMD); + else if (strcmp(optarg, "udoy") == 0) + timestamp_set_type(TS_UTC_WITH_YDOY); else { cmdarg_err("Invalid time stamp type \"%s\"", optarg); - cmdarg_err_cont("It must be \"a\" for absolute, \"ad\" for absolute with date, \"d\" for delta,"); - cmdarg_err_cont("\"dd\" for delta displayed, \"e\" for epoch, \"r\" for relative, \"u\" for UTC, "); - cmdarg_err_cont("or \"ud\" for UTC with date."); + cmdarg_err_cont( +"It must be \"a\" for absolute, \"ad\" for absolute with YYYY-MM-DD date,"); + cmdarg_err_cont( +"\"adoy\" for absolute with YYYY/DOY date, \"d\" for delta,"); + cmdarg_err_cont( +"\"dd\" for delta displayed, \"e\" for epoch, \"r\" for relative,"); + cmdarg_err_cont( +"\"u\" for absolute UTC, \"ud\" for absolute UTC with YYYY-MM-DD date,"); + cmdarg_err_cont( +"or \"udoy\" for absolute UTC with YYYY/DOY date."); exit(1); } break; diff --git a/ui/gtk/main_menubar.c b/ui/gtk/main_menubar.c index 410217792e..be5fc6c0d9 100644 --- a/ui/gtk/main_menubar.c +++ b/ui/gtk/main_menubar.c @@ -1045,13 +1045,15 @@ static const char *ui_desc_menubar = " \n" " \n" " \n" -" \n" +" \n" +" \n" " \n" " \n" " \n" " \n" " \n" -" \n" +" \n" +" \n" " \n" " \n" " \n" @@ -1797,13 +1799,15 @@ static const GtkToggleActionEntry main_menu_bar_toggle_action_entries[] = static const GtkRadioActionEntry main_menu_bar_radio_view_time_entries [] = { /* name, stock id, label, accel, tooltip, value */ - { "/View/TimeDisplayFormat/DateandTimeofDay", NULL, "Date and Time of Day: 1970-01-01 01:02:03.123456", "1", NULL, TS_ABSOLUTE_WITH_DATE }, + { "/View/TimeDisplayFormat/DateYMDandTimeofDay", NULL, "Date and Time of Day: 1970-01-01 01:02:03.123456", "1", NULL, TS_ABSOLUTE_WITH_YMD }, + { "/View/TimeDisplayFormat/DateYDOYandTimeofDay", NULL, "Date (with day of year) and Time of Day: 1970/001 01:02:03.123456", NULL, NULL, TS_ABSOLUTE_WITH_YDOY }, { "/View/TimeDisplayFormat/TimeofDay", NULL, "Time of Day: 01:02:03.123456", "2", NULL, TS_ABSOLUTE }, { "/View/TimeDisplayFormat/SecondsSinceEpoch", NULL, "Seconds Since Epoch (1970-01-01): 1234567890.123456", "3", NULL, TS_EPOCH }, { "/View/TimeDisplayFormat/SecondsSinceBeginningofCapture", NULL, "Seconds Since Beginning of Capture: 123.123456", "4", NULL, TS_RELATIVE }, { "/View/TimeDisplayFormat/SecondsSincePreviousCapturedPacket", NULL, "Seconds Since Previous Captured Packet: 1.123456", "5", NULL, TS_DELTA }, { "/View/TimeDisplayFormat/SecondsSincePreviousDisplayedPacket",NULL, "Seconds Since Previous Displayed Packet: 1.123456", "6", NULL, TS_DELTA_DIS }, - { "/View/TimeDisplayFormat/UTCDateandTimeofDay", NULL, "UTC Date and Time of Day: 1970-01-01 01:02:03.123456", "7", NULL, TS_UTC_WITH_DATE }, + { "/View/TimeDisplayFormat/UTCDateYMDandTimeofDay", NULL, "UTC Date and Time of Day: 1970-01-01 01:02:03.123456", "7", NULL, TS_UTC_WITH_YMD }, + { "/View/TimeDisplayFormat/UTCDateYDOYandTimeofDay", NULL, "UTC Date (with day of year) and Time of Day: 1970/001 01:02:03.123456", NULL, NULL, TS_UTC_WITH_YDOY }, { "/View/TimeDisplayFormat/UTCTimeofDay", NULL, "UTC Time of Day: 01:02:03.123456", "7", NULL, TS_UTC }, };