Bug 209699 - kdump: "stime" should be "mtime" in struct stat decoding
Summary: kdump: "stime" should be "mtime" in struct stat decoding
Status: Closed FIXED
Alias: None
Product: Base System
Classification: Unclassified
Component: bin (show other bugs)
Version: CURRENT
Hardware: Any Any
: --- Affects Many People
Assignee: Enji Cooper
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2016-05-22 17:45 UTC by Christian Weisgerber
Modified: 2016-06-08 13:46 UTC (History)
1 user (show)

See Also:
ngie: mfc-stable10+
ngie: mfc-stable9+


Attachments
kdump.c patch (352 bytes, patch)
2016-05-22 17:45 UTC, Christian Weisgerber
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Christian Weisgerber freebsd_committer freebsd_triage 2016-05-22 17:45:56 UTC
Created attachment 170553 [details]
kdump.c patch

When kdump decodes struct stat, the mtime field is labeled "stime":

 74440 ls       CALL  fstatat(AT_FDCWD,0x801846388,0x801846310,0x200)
 74440 ls       NAMI  "foo"
 74440 ls       STRU  struct stat {dev=121, ino=2812114, mode=0100644, nlink=1, uid=1000, gid=1000, rdev=0, atime=1463938446.572306000, stime=1463938446.572306000, ctime=1463938446.572306000, birthtime=1463938446.572304000, size=0, blksize=32768, blocks=0, flags=0x0 }
 74440 ls       RET   fstatat 0

I can't think of a good reason for this. Maybe a typo? Trivial patch attached.

Noticed on 10.3-STABLE, but it still applies to 11.0-CURRENT.
Comment 1 commit-hook freebsd_committer freebsd_triage 2016-05-22 18:16:37 UTC
A commit references this bug:

Author: ngie
Date: Sun May 22 18:16:05 UTC 2016
New revision: 300426
URL: https://svnweb.freebsd.org/changeset/base/300426

Log:
  Fix humanized decoding of struct stat with respect to .st_mtim

  st_mtim was being incorrectly described as "stime=", not "mtime=". This was
  introduced with the original feature commit (r176471).

  MFC after: 1 week
  PR: 209699
  Submitted by: naddy
  Sponsored by: EMC / Isilon Storage Division

Changes:
  projects/vmware_pvscsi/usr.bin/kdump/kdump.c
Comment 2 commit-hook freebsd_committer freebsd_triage 2016-05-22 18:21:38 UTC
A commit references this bug:

Author: ngie
Date: Sun May 22 18:20:46 UTC 2016
New revision: 300428
URL: https://svnweb.freebsd.org/changeset/base/300428

Log:
  Fix humanized decoding of struct stat with respect to .st_mtim

  st_mtim was being incorrectly described as "stime=", not "mtime=". This was
  introduced with the original feature commit (r176471).

  MFC after: 1 week
  PR: 209699
  Submitted by: naddy
  Sponsored by: EMC / Isilon Storage Division

Changes:
  head/usr.bin/kdump/kdump.c
Comment 3 commit-hook freebsd_committer freebsd_triage 2016-06-08 13:44:37 UTC
A commit references this bug:

Author: ngie
Date: Wed Jun  8 13:44:01 UTC 2016
New revision: 301617
URL: https://svnweb.freebsd.org/changeset/base/301617

Log:
  MFC r300428:

  Fix humanized decoding of struct stat with respect to .st_mtim

  st_mtim was being incorrectly described as "stime=", not "mtime=". This was
  introduced with the original feature commit (r176471).

  PR: 209699

Changes:
_U  stable/10/
  stable/10/usr.bin/kdump/kdump.c
Comment 4 commit-hook freebsd_committer freebsd_triage 2016-06-08 13:45:38 UTC
A commit references this bug:

Author: ngie
Date: Wed Jun  8 13:45:02 UTC 2016
New revision: 301618
URL: https://svnweb.freebsd.org/changeset/base/301618

Log:
  MFstable/10 r301617:

  MFC r300428:

  Fix humanized decoding of struct stat with respect to .st_mtim

  st_mtim was being incorrectly described as "stime=", not "mtime=". This was
  introduced with the original feature commit (r176471).

  PR: 209699

Changes:
_U  stable/9/
_U  stable/9/usr.bin/
_U  stable/9/usr.bin/kdump/
  stable/9/usr.bin/kdump/kdump.c