diff options
Diffstat (limited to 'cmds/dumpstate/dumpstate.c')
-rw-r--r-- | cmds/dumpstate/dumpstate.c | 18 |
1 files changed, 13 insertions, 5 deletions
diff --git a/cmds/dumpstate/dumpstate.c b/cmds/dumpstate/dumpstate.c index 6a00e3e..c211b47 100644 --- a/cmds/dumpstate/dumpstate.c +++ b/cmds/dumpstate/dumpstate.c @@ -333,10 +333,18 @@ int main(int argc, char *argv[]) { static void dump_kernel_log(const char *path, const char *title) { - printf("------ KERNEL %s LOG ------\n", title); - if (access(path, R_OK) < 0) - printf("%s: %s\n", path, strerror(errno)); - else - DUMP(path); + printf("------ KERNEL %s LOG ------\n", title); + if (access(path, R_OK) < 0) + printf("%s: %s\n", path, strerror(errno)); + else { + struct stat sbuf; + + if (stat(path, &sbuf) < 0) + printf("%s: stat failed (%s)\n", path, strerror(errno)); + else + printf("Harvested %s", ctime(&sbuf.st_ctime)); + + DUMP(path); + } } |