dumpstate: Add the ctime (time the file was harvested out of /proc) to dump.
Signed-off-by: San Mehat <san@google.com>
This commit is contained in:
@@ -333,10 +333,18 @@ int main(int argc, char *argv[]) {
|
|||||||
static void dump_kernel_log(const char *path, const char *title)
|
static void dump_kernel_log(const char *path, const char *title)
|
||||||
|
|
||||||
{
|
{
|
||||||
printf("------ KERNEL %s LOG ------\n", title);
|
printf("------ KERNEL %s LOG ------\n", title);
|
||||||
if (access(path, R_OK) < 0)
|
if (access(path, R_OK) < 0)
|
||||||
printf("%s: %s\n", path, strerror(errno));
|
printf("%s: %s\n", path, strerror(errno));
|
||||||
else
|
else {
|
||||||
DUMP(path);
|
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);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user