]> The Tcpdump Group git mirrors - tcpdump/commitdiff
smbutil.c: Use the "%Y-%m-%d" date format
authorFrancois-Xavier Le Bail <[email protected]>
Thu, 21 Mar 2024 19:31:43 +0000 (20:31 +0100)
committerFrancois-Xavier Le Bail <[email protected]>
Thu, 21 Mar 2024 19:36:59 +0000 (20:36 +0100)
Replace "%Y/%m/%d" with "%Y-%m-%d" like in most date formats.

%T is equivalent to %H:%M:%S.

Moreover: Fix indentation.

smbutil.c

index e366ae4b66898d5c5b56f0417536ac64b6003600..b9125162c9461de0768944d1a5b9680a24573424 100644 (file)
--- a/smbutil.c
+++ b/smbutil.c
@@ -800,8 +800,8 @@ smb_fdata1(netdissect_options *ndo,
                break;
            }
            if (t != 0) {
-                   tstring = nd_format_time(buffer, sizeof(buffer), "%a %b %e %T %Y",
-                   localtime(&t));
+               tstring = nd_format_time(buffer, sizeof(buffer), "%Y-%m-%d %T",
+                                        localtime(&t));
            } else
                tstring = "NULL";
            ND_PRINT("%s\n", tstring);