universal7885: debug_daemon: run clang-format

Signed-off-by: roynatech2544 <whiteshell2544@naver.com>
This commit is contained in:
roynatech2544 2021-12-14 14:13:06 +09:00
commit 7db5c03bac
No known key found for this signature in database
GPG key ID: 9675C32163D88D30
3 changed files with 19 additions and 21 deletions

View file

@ -19,26 +19,25 @@
#define WRITE_KMSG "/data/debug/logs/kmsg.txt"
#define LOG_TAG "DebugKmsgDaemon"
#include <fstream>
#include <log/log.h>
#include <fstream>
bool check_data(){
bool check_data() {
std::ifstream datafile(CHECK_KMSG);
if(datafile.good()){
datafile.close();
if (datafile.good()) {
datafile.close();
ALOGI("Found %s, logging...", CHECK_KMSG);
return true;
}else{
} else {
ALOGW("Couldn't find %s, not logging...", CHECK_KMSG);
return false;
}
}
void copy_kmsg(){
if(check_data()){
std::ifstream readfile(KMSG_PATH);
std::ofstream writefile(WRITE_KMSG);
writefile << readfile.rdbuf();
void copy_kmsg() {
if (check_data()) {
std::ifstream readfile(KMSG_PATH);
std::ofstream writefile(WRITE_KMSG);
writefile << readfile.rdbuf();
}
}