mirror of
https://github.com/openharmony/xts_device_attest_lite.git
synced 2026-06-30 21:57:55 -04:00
Executable → Regular
+1
-3
@@ -34,9 +34,7 @@ config("devattest_core_config") {
|
||||
|
||||
defines = []
|
||||
if (enable_attest_log_debug) {
|
||||
defines += [ "ATTEST_HILOG_LEVEL = 0" ]
|
||||
} else {
|
||||
defines += [ "ATTEST_HILOG_LEVEL = 1" ]
|
||||
defines += [ "__ATTEST_HILOG_LEVEL_DEBUG__" ]
|
||||
}
|
||||
|
||||
if (enable_attest_mock_network) {
|
||||
|
||||
@@ -72,9 +72,11 @@ static void AttestLogPrint(AttestLogLevel logLevel, const char *logBuf)
|
||||
|
||||
void AttestLog(AttestLogLevel logLevel, const char* fmt, ...)
|
||||
{
|
||||
if (logLevel < ATTEST_HILOG_LEVEL) {
|
||||
#ifndef __ATTEST_HILOG_LEVEL_DEBUG__
|
||||
if (logLevel == ATTEST_LOG_LEVEL_DEBUG) {
|
||||
return;
|
||||
}
|
||||
#endif
|
||||
char outStr[ATTEST_LOG_STR_LEM] = {0};
|
||||
va_list arg;
|
||||
va_start(arg, fmt);
|
||||
@@ -89,7 +91,12 @@ void AttestLog(AttestLogLevel logLevel, const char* fmt, ...)
|
||||
|
||||
void AttestLogAnonyStr(AttestLogLevel logLevel, const char* fmt, const char* str)
|
||||
{
|
||||
if (fmt == NULL || str == NULL || logLevel < ATTEST_HILOG_LEVEL) {
|
||||
#ifndef __ATTEST_HILOG_LEVEL_DEBUG__
|
||||
if (logLevel == ATTEST_LOG_LEVEL_DEBUG) {
|
||||
return;
|
||||
}
|
||||
#endif
|
||||
if (fmt == NULL || str == NULL) {
|
||||
return;
|
||||
}
|
||||
char *strDup = AttestStrdup(str);
|
||||
|
||||
@@ -32,8 +32,7 @@ if (ohos_kernel_type == "liteos_a" || ohos_kernel_type == "linux") {
|
||||
"-fPIC",
|
||||
"-pthread",
|
||||
]
|
||||
defines = [ "ATTEST_HILOG_LEVEL = 1" ]
|
||||
defines += [ "MBEDTLS_ALLOW_PRIVATE_ACCESS" ]
|
||||
defines = [ "MBEDTLS_ALLOW_PRIVATE_ACCESS" ]
|
||||
include_dirs = include_core_dirs
|
||||
include_dirs += [
|
||||
".",
|
||||
|
||||
Reference in New Issue
Block a user