mirror of
https://github.com/openharmony/security_device_auth.git
synced 2026-08-24 10:02:51 -04:00
!1314 merge fix_cfi_error_hichainsdk into master
fix method signature not same in hichain.h and log.c
Created-by: Chuxiong_KOU
Commit-by: kou-chuxiong
Merged-by: openharmony_ci
Description: ### 一、内容说明(相关的Issue)
### 二、建议测试周期和提测地址
建议测试完成时间:xxxx.xx.xx
投产上线时间:xxxx.xx.xx
提测地址:CI环境/压测环境
测试账号:
### 三、变更内容
* 3.1 关联PR列表
* 3.2 数据库和部署说明
1. 常规更新
2. 重启unicorn
3. 重启sidekiq
4. 迁移任务:是否有迁移任务,没有写 "无"
5. rake脚本:`bundle exec xxx RAILS_ENV = production`;没有写 "无"
* 3.4 其他技术优化内容(做了什么,变更了什么)
- 重构了 xxxx 代码
- xxxx 算法优化
* 3.5 废弃通知(什么字段、方法弃用?)
* 3.6 后向不兼容变更(是否有无法向后兼容的变更?)
### 四、研发自测点(自测哪些?冒烟用例全部自测?)
自测测试结论:
### 五、测试关注点(需要提醒QA重点关注的、可能会忽略的地方)
检查点:
| 需求名称 | 是否影响xx公共模块 | 是否需要xx功能 | 需求升级是否依赖其他子产品 |
|------|------------|----------|---------------|
| xxx | 否 | 需要 | 不需要 |
| | | | |
接口测试:
性能测试:
并发测试:
其他:
See merge request: openharmony/security_device_auth!1314
This commit is contained in:
@@ -16,22 +16,15 @@
|
||||
#ifndef __LOG_H__
|
||||
#define __LOG_H__
|
||||
|
||||
typedef void (*log_f)(const char *tag, const char *func_name, const char *format, ...);
|
||||
|
||||
struct log_f_group {
|
||||
log_f log_d;
|
||||
log_f log_i;
|
||||
log_f log_w;
|
||||
log_f log_e;
|
||||
};
|
||||
#include "hichain.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
log_f get_logd(void);
|
||||
log_f get_logi(void);
|
||||
log_f get_logw(void);
|
||||
log_f get_loge(void);
|
||||
log_func get_logd(void);
|
||||
log_func get_logi(void);
|
||||
log_func get_logw(void);
|
||||
log_func get_loge(void);
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
@@ -19,45 +19,35 @@
|
||||
#include "securec.h"
|
||||
#include "base.h"
|
||||
|
||||
#if defined(_WINDOWS)
|
||||
#ifdef DLL_EXPORT
|
||||
#define DLL_API_PUBLIC __declspec(dllexport)
|
||||
#else
|
||||
#define DLL_API_PUBLIC __declspec(dllimport)
|
||||
#endif
|
||||
#else
|
||||
#define DLL_API_PUBLIC __attribute__ ((visibility("default")))
|
||||
#endif
|
||||
|
||||
static void hc_logd(const char *tag, const char *func, const char *format, ...);
|
||||
static void hc_logi(const char *tag, const char *func, const char *format, ...);
|
||||
static void hc_logw(const char *tag, const char *func, const char *format, ...);
|
||||
static void hc_loge(const char *tag, const char *func, const char *format, ...);
|
||||
|
||||
static struct log_f_group g_log_func = { hc_logd, hc_logi, hc_logw, hc_loge };
|
||||
static struct log_func_group g_log_func = { hc_logd, hc_logi, hc_logw, hc_loge };
|
||||
|
||||
log_f get_logd(void)
|
||||
log_func get_logd(void)
|
||||
{
|
||||
return g_log_func.log_d;
|
||||
}
|
||||
|
||||
log_f get_logi(void)
|
||||
log_func get_logi(void)
|
||||
{
|
||||
return g_log_func.log_i;
|
||||
}
|
||||
|
||||
log_f get_logw(void)
|
||||
log_func get_logw(void)
|
||||
{
|
||||
return g_log_func.log_w;
|
||||
}
|
||||
|
||||
log_f get_loge(void)
|
||||
log_func get_loge(void)
|
||||
{
|
||||
return g_log_func.log_e;
|
||||
}
|
||||
|
||||
/* no log without register */
|
||||
DLL_API_PUBLIC void registe_log(struct log_f_group *log)
|
||||
DLL_API_PUBLIC void registe_log(struct log_func_group *log)
|
||||
{
|
||||
check_ptr_return(log);
|
||||
|
||||
|
||||
@@ -24,8 +24,10 @@
|
||||
#else
|
||||
#define DLL_API_PUBLIC __declspec(dllimport)
|
||||
#endif
|
||||
#else
|
||||
#elif defined(__GNUC__) || defined(__clang__)
|
||||
#define DLL_API_PUBLIC __attribute__ ((visibility("default")))
|
||||
#else
|
||||
#define DLL_API_PUBLIC
|
||||
#endif
|
||||
|
||||
#ifdef HILINK_E2E_SECURITY_CONFIG
|
||||
|
||||
Reference in New Issue
Block a user