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

Fix line breaks characters breaking syslog messages #9881

Closed
wants to merge 7 commits into from
Closed

Fix line breaks characters breaking syslog messages #9881

wants to merge 7 commits into from

Conversation

amadeo-alex
Copy link
Contributor

Hello,

This simple change removes \r & \n characters from the commit hash. I don't know how they ended there but this makes sure that even if they do, they are removed before logging.
Before the change:
obraz
After the change:
obraz

This would cause some syslog servers freak out and treat all logs as one message.
Previously added as a PR to master branch, please excuse my mistake.
Possible relation to #9872

@amadeo-alex amadeo-alex marked this pull request as ready for review November 28, 2021 21:52
@nurikk
Copy link
Collaborator

nurikk commented Nov 29, 2021

it would be better to trim commitHash in getZigbee2MQTTVersion

@amadeo-alex
Copy link
Contributor Author

Ah, wanted to do the change in GitHub UI. Lesson learned. I'll close this one and open proper with the fix in utils.ts.

@sonarqubecloud
Copy link

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

No Coverage information No Coverage information
No Duplication information No Duplication information

@amadeo-alex amadeo-alex deleted the syslog_line_break_fix branch November 29, 2021 17:44
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

Successfully merging this pull request may close these issues.

4 participants