Change su logs time granularity

This commit is contained in:
topjohnwu
2017-07-24 01:20:03 +08:00
parent 356065d1ee
commit ab199d883d
2 changed files with 9 additions and 5 deletions
@@ -30,7 +30,7 @@ public class SuLogEntry {
appName = c.getString(c.getColumnIndex("app_name"));
command = c.getString(c.getColumnIndex("command"));
action = c.getInt(c.getColumnIndex("action")) != 0;
date = new Date(c.getLong(c.getColumnIndex("time")) * 1000);
date = new Date(c.getLong(c.getColumnIndex("time")));
}
public ContentValues getContentValues() {
@@ -42,7 +42,7 @@ public class SuLogEntry {
values.put("command", command);
values.put("to_uid", toUid);
values.put("action", action ? 1 : 0);
values.put("time", date.getTime() / 1000);
values.put("time", date.getTime());
return values;
}