Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add millisecond precision to nsjail logs #206

Open
phoebetse opened this issue Oct 25, 2022 · 1 comment
Open

Add millisecond precision to nsjail logs #206

phoebetse opened this issue Oct 25, 2022 · 1 comment

Comments

@phoebetse
Copy link

phoebetse commented Oct 25, 2022

I'd like to see logs with timestamps with millisecond precision.

I'm not super familiar with C++, but I think https://github.com/google/nsjail/blob/master/util.cc#L311 is where the change would need to be. It looks like the timeToStr utility function is outputting a string to second precision, so maybe using something like gettimeofday as mentioned on stackexchange would work?

Would a change like this make sense? If so, I'm happy to take a stab at it.

@disconnect3d
Copy link
Contributor

Hi,

I think it would make sense and while I am not a maintainer, I think it may get merged :P.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants