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 timestamps to debug log messages #312

Closed
wants to merge 1 commit into from
Closed

Conversation

Strykar
Copy link

@Strykar Strykar commented Jan 10, 2024

  • Introduced get_timestamp function to generate current time in a thread-safe manner using localtime_r.
  • Modified do_log function to prepend timestamps to each log message.
  • Defined TIMELEN constant for timestamp buffer size.
  • Timestamp is included in both syslog and file output.
  • Closes Timestamp debug logs #311

- Introduced `get_timestamp` function to generate current time in a thread-safe manner using `localtime_r`.
- Modified `do_log` function to prepend timestamps to each log message.
- Defined `TIMELEN` constant for timestamp buffer size.
- Timestamp is included in both syslog and file output.
- Closes Yubico#311
@LDVG
Copy link
Contributor

LDVG commented Jan 15, 2024

Hi,

Considering you should be able to get timestamps through e.g. syslog already and that we haven't seen the use for this very often, we'll be closing this for now. We'll keep it in mind if we need it in the future. Thanks for contributing!

@LDVG LDVG closed this Jan 15, 2024
@LDVG LDVG mentioned this pull request Jan 15, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

Timestamp debug logs
2 participants