forked from open-vela/external_avb
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
sysdeps: Add support for vfprintf() logging
Introduce a build flag to make logging calls (avb_{debug,error,fatal}) use vfprintf(3) instead of printf(3), which greatly improves the probability of the call resulting in a single write(2), as opposed to our current implementation of avb_printv(), which calls fprintf(3) once per received argument. This is useful when stderr points to a file that is shared and/or format entries per write(2) call, such as /dev/kmsg. Note that client code passing the now deprecated NULL sentinel to the logging macros avb_{debug,error,fatal}() must NOT enable this feature. Test: - Reported-by: JeongHyeon Lee <[email protected]> Change-Id: I0f30d21939fca7ceb9e96ac7d443512fe7c301d9
- Loading branch information
1 parent
2421c10
commit 592e186
Showing
4 changed files
with
49 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters