From 7add9ebea570161258b633e94631712a268dd56e Mon Sep 17 00:00:00 2001 From: l00520400 Date: Wed, 16 Feb 2022 19:01:03 +0800 Subject: [PATCH] warning Signed-off-by: l00520400 Change-Id: I3c4bcc6315aa858ff6856ad6800f87155063240e Signed-off-by: l00520400 --- frameworks/common/include/data_validator.h | 5 +++-- frameworks/common/include/random.h | 2 +- .../main/cpp/include/token/native_token_info_inner.h | 4 ++-- .../main/cpp/src/token/accesstoken_id_manager.cpp | 3 --- 4 files changed, 6 insertions(+), 8 deletions(-) diff --git a/frameworks/common/include/data_validator.h b/frameworks/common/include/data_validator.h index 8821598cf..b96679969 100644 --- a/frameworks/common/include/data_validator.h +++ b/frameworks/common/include/data_validator.h @@ -13,11 +13,12 @@ * limitations under the License. */ +#ifndef DATA_VALIDATOR_H +#define DATA_VALIDATOR_H + #include #include "access_token.h" -#ifndef DATA_VALIDATOR_H -#define DATA_VALIDATOR_H namespace OHOS { namespace Security { namespace AccessToken { diff --git a/frameworks/common/include/random.h b/frameworks/common/include/random.h index 936276421..278cc24aa 100644 --- a/frameworks/common/include/random.h +++ b/frameworks/common/include/random.h @@ -22,7 +22,7 @@ extern "C" { #endif #endif -unsigned int GetRandomUint32(); +unsigned int GetRandomUint32(void); #ifdef __cplusplus #if __cplusplus diff --git a/services/accesstokenmanager/main/cpp/include/token/native_token_info_inner.h b/services/accesstokenmanager/main/cpp/include/token/native_token_info_inner.h index 527d176d1..f76e1ba05 100644 --- a/services/accesstokenmanager/main/cpp/include/token/native_token_info_inner.h +++ b/services/accesstokenmanager/main/cpp/include/token/native_token_info_inner.h @@ -16,11 +16,11 @@ #ifndef ACCESSTOKEN_NATIVE_TOKEN_INFO_INNER_H #define ACCESSTOKEN_NATIVE_TOKEN_INFO_INNER_H -#include "access_token.h" -#include "native_token_info.h" #include #include +#include "access_token.h" #include "generic_values.h" +#include "native_token_info.h" namespace OHOS { namespace Security { diff --git a/services/accesstokenmanager/main/cpp/src/token/accesstoken_id_manager.cpp b/services/accesstokenmanager/main/cpp/src/token/accesstoken_id_manager.cpp index 7bedb7555..3d1421b82 100644 --- a/services/accesstokenmanager/main/cpp/src/token/accesstoken_id_manager.cpp +++ b/services/accesstokenmanager/main/cpp/src/token/accesstoken_id_manager.cpp @@ -14,9 +14,6 @@ */ #include "accesstoken_id_manager.h" - -#include - #include "accesstoken_log.h" #include "data_validator.h" #include "random.h" -- Gitee