summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJacob Keeler <jacob.keeler@livioradio.com>2016-09-21 10:27:43 -0400
committerJacob Keeler <jacob.keeler@livioradio.com>2016-09-21 10:27:43 -0400
commit0fdd32f58dbedf7e175d5ab8b3e04b4edd3d9526 (patch)
treec8e182f05b28e4264846141c733a43c4a72de460
parentdd6c53b143992f967cd42a7c5c327e57e80a217e (diff)
downloadsdl_core-0fdd32f58dbedf7e175d5ab8b3e04b4edd3d9526.tar.gz
Fix style issues
-rw-r--r--src/components/application_manager/include/application_manager/application.h5
-rw-r--r--src/components/application_manager/include/application_manager/commands/mobile/create_interaction_choice_set_request.h3
-rw-r--r--src/components/application_manager/include/application_manager/request_info.h2
-rw-r--r--src/components/application_manager/src/commands/mobile/get_vehicle_data_request.cc4
-rw-r--r--src/components/application_manager/src/message.cc3
-rw-r--r--src/components/application_manager/src/request_info.cc2
-rw-r--r--src/components/config_profile/src/ini_file.cc3
-rw-r--r--src/components/config_profile/src/profile.cc3
-rw-r--r--src/components/include/policy/usage_statistics/statistics_manager.h10
-rw-r--r--src/components/media_manager/src/audio/from_mic_recorder_listener.cc2
-rw-r--r--src/components/rpc_base/include/rpc_base/rpc_base_json_inl.h4
-rw-r--r--src/components/transport_manager/src/bluetooth/bluetooth_socket_connection.cc4
-rw-r--r--src/components/transport_manager/src/tcp/tcp_client_listener.cc24
-rw-r--r--src/components/utils/src/file_system.cc8
14 files changed, 41 insertions, 36 deletions
diff --git a/src/components/application_manager/include/application_manager/application.h b/src/components/application_manager/include/application_manager/application.h
index 20a8c9b3b0..2c6a27c5f4 100644
--- a/src/components/application_manager/include/application_manager/application.h
+++ b/src/components/application_manager/include/application_manager/application.h
@@ -87,11 +87,10 @@ struct Version {
struct AppFile {
// need to use in std::map;
- AppFile()
+ AppFile()
: is_persistent(false)
, is_download_complete(false)
- , file_type(mobile_apis::FileType::INVALID_ENUM) {
- }
+ , file_type(mobile_apis::FileType::INVALID_ENUM) {}
AppFile(const std::string& name,
bool persistent,
bool download_complete,
diff --git a/src/components/application_manager/include/application_manager/commands/mobile/create_interaction_choice_set_request.h b/src/components/application_manager/include/application_manager/commands/mobile/create_interaction_choice_set_request.h
index 32fed1eee1..d66db3d548 100644
--- a/src/components/application_manager/include/application_manager/commands/mobile/create_interaction_choice_set_request.h
+++ b/src/components/application_manager/include/application_manager/commands/mobile/create_interaction_choice_set_request.h
@@ -103,8 +103,7 @@ class CreateInteractionChoiceSetRequest : public CommandRequestImpl {
* processing deleting sent commands if error from HMI received
*/
struct VRCommandInfo {
- VRCommandInfo()
- : cmd_id_(0), succesful_response_received_(false) {}
+ VRCommandInfo() : cmd_id_(0), succesful_response_received_(false) {}
VRCommandInfo(uint32_t cmd_id)
: cmd_id_(cmd_id), succesful_response_received_(false) {}
uint32_t cmd_id_;
diff --git a/src/components/application_manager/include/application_manager/request_info.h b/src/components/application_manager/include/application_manager/request_info.h
index c0a85e1f5e..0d4a147bda 100644
--- a/src/components/application_manager/include/application_manager/request_info.h
+++ b/src/components/application_manager/include/application_manager/request_info.h
@@ -53,7 +53,7 @@ namespace request_controller {
*
*/
typedef utils::SharedPtr<commands::Command> RequestPtr;
-
+
struct RequestInfo {
enum RequestType { RequestNone, MobileRequest, HMIRequest };
diff --git a/src/components/application_manager/src/commands/mobile/get_vehicle_data_request.cc b/src/components/application_manager/src/commands/mobile/get_vehicle_data_request.cc
index b4c6db9b91..dc36e9ad3a 100644
--- a/src/components/application_manager/src/commands/mobile/get_vehicle_data_request.cc
+++ b/src/components/application_manager/src/commands/mobile/get_vehicle_data_request.cc
@@ -271,8 +271,8 @@ void GetVehicleDataRequest::on_event(const event_engine::Event& event) {
message[strings::params][hmi_response::code].asInt());
bool result = false;
if (mobile_apis::Result::SUCCESS == result_code ||
- (mobile_apis::Result::VEHICLE_DATA_NOT_AVAILABLE == result_code
- && message[strings::msg_params].length() > 1)) {
+ (mobile_apis::Result::VEHICLE_DATA_NOT_AVAILABLE == result_code &&
+ message[strings::msg_params].length() > 1)) {
result = true;
}
const char* info = NULL;
diff --git a/src/components/application_manager/src/message.cc b/src/components/application_manager/src/message.cc
index 1dbac42010..2206cf479f 100644
--- a/src/components/application_manager/src/message.cc
+++ b/src/components/application_manager/src/message.cc
@@ -67,8 +67,7 @@ Message::Message(protocol_handler::MessagePriority priority)
, version_(kUnknownProtocol) {}
Message::Message(const Message& message)
- : priority_(message.priority_),
- binary_data_(NULL) {
+ : priority_(message.priority_), binary_data_(NULL) {
*this = message;
}
diff --git a/src/components/application_manager/src/request_info.cc b/src/components/application_manager/src/request_info.cc
index 1826e67a0d..d951d396d9 100644
--- a/src/components/application_manager/src/request_info.cc
+++ b/src/components/application_manager/src/request_info.cc
@@ -76,7 +76,7 @@ MobileRequestInfo::MobileRequestInfo(RequestPtr request,
RequestInfo::RequestInfo(RequestPtr request,
const RequestInfo::RequestType requst_type,
const TimevalStruct& start_time,
- const uint64_t timeout_msec)
+ const uint64_t timeout_msec)
: request_(request)
, start_time_(start_time)
, timeout_msec_(timeout_msec)
diff --git a/src/components/config_profile/src/ini_file.cc b/src/components/config_profile/src/ini_file.cc
index d4d6208401..3245b096cb 100644
--- a/src/components/config_profile/src/ini_file.cc
+++ b/src/components/config_profile/src/ini_file.cc
@@ -278,7 +278,8 @@ char ini_write_value(const char* fname,
if (0 != rename(temp_fname, fname)) {
if (0 != remove(temp_fname)) {
- LOG4CXX_WARN_WITH_ERRNO(logger_, "Unable to remove temp file: " << std::string(temp_fname));
+ LOG4CXX_WARN_WITH_ERRNO(
+ logger_, "Unable to remove temp file: " << std::string(temp_fname));
}
return FALSE;
}
diff --git a/src/components/config_profile/src/profile.cc b/src/components/config_profile/src/profile.cc
index 9224a454a3..b5ea924b49 100644
--- a/src/components/config_profile/src/profile.cc
+++ b/src/components/config_profile/src/profile.cc
@@ -315,7 +315,8 @@ Profile::Profile()
, max_cmd_id_(kDefaultMaxCmdId)
, default_timeout_(kDefaultTimeout)
, app_resuming_timeout_(kDefaultAppResumingTimeout)
- , app_resumption_save_persistent_data_timeout_(kDefaultAppSavePersistentDataTimeout)
+ , app_resumption_save_persistent_data_timeout_(
+ kDefaultAppSavePersistentDataTimeout)
, app_dir_quota_(kDefaultDirQuota)
, app_hmi_level_none_time_scale_max_requests_(
kDefaultAppHmiLevelNoneTimeScaleMaxRequests)
diff --git a/src/components/include/policy/usage_statistics/statistics_manager.h b/src/components/include/policy/usage_statistics/statistics_manager.h
index 6f52c89f30..4a387b8b13 100644
--- a/src/components/include/policy/usage_statistics/statistics_manager.h
+++ b/src/components/include/policy/usage_statistics/statistics_manager.h
@@ -38,11 +38,11 @@
namespace usage_statistics {
-enum GlobalCounterId {
- GLOBAL_COUNTER_NONE,
- IAP_BUFFER_FULL,
- SYNC_OUT_OF_MEMORY,
- SYNC_REBOOTS
+enum GlobalCounterId {
+ GLOBAL_COUNTER_NONE,
+ IAP_BUFFER_FULL,
+ SYNC_OUT_OF_MEMORY,
+ SYNC_REBOOTS
};
enum AppInfoId { APP_INFO_NONE, LANGUAGE_GUI, LANGUAGE_VUI };
diff --git a/src/components/media_manager/src/audio/from_mic_recorder_listener.cc b/src/components/media_manager/src/audio/from_mic_recorder_listener.cc
index fc55e69d28..647db1e1a3 100644
--- a/src/components/media_manager/src/audio/from_mic_recorder_listener.cc
+++ b/src/components/media_manager/src/audio/from_mic_recorder_listener.cc
@@ -42,7 +42,7 @@ CREATE_LOGGERPTR_GLOBAL(logger_, "MediaManager")
FromMicRecorderListener::FromMicRecorderListener(
const std::string& file_name,
application_manager::ApplicationManager& app_mngr)
- : reader_(NULL)
+ : reader_(NULL)
, file_name_(file_name)
, current_application_(0)
, application_manager_(app_mngr) {}
diff --git a/src/components/rpc_base/include/rpc_base/rpc_base_json_inl.h b/src/components/rpc_base/include/rpc_base/rpc_base_json_inl.h
index c7854ede43..31f8c90872 100644
--- a/src/components/rpc_base/include/rpc_base/rpc_base_json_inl.h
+++ b/src/components/rpc_base/include/rpc_base/rpc_base_json_inl.h
@@ -351,8 +351,8 @@ inline Json::Value Nullable<T>::ToJsonValue() const {
template <typename T>
template <typename U>
Optional<T>::Optional(const Json::Value* value, const U& def_value)
- : policy_table_type_(policy_table_interface_base::INVALID_PT_TYPE)
- , value_(value, def_value) {}
+ : policy_table_type_(policy_table_interface_base::INVALID_PT_TYPE)
+ , value_(value, def_value) {}
template <typename T>
inline Json::Value Optional<T>::ToJsonValue() const {
diff --git a/src/components/transport_manager/src/bluetooth/bluetooth_socket_connection.cc b/src/components/transport_manager/src/bluetooth/bluetooth_socket_connection.cc
index 3d136532d9..ad000ab901 100644
--- a/src/components/transport_manager/src/bluetooth/bluetooth_socket_connection.cc
+++ b/src/components/transport_manager/src/bluetooth/bluetooth_socket_connection.cc
@@ -104,9 +104,9 @@ bool BluetoothSocketConnection::Establish(ConnectError** error) {
if (0 == connect_status) {
LOG4CXX_DEBUG(logger_, "rfcomm Connect ok");
break;
- } else { // If connect_status is not 0, an errno is returned
+ } else { // If connect_status is not 0, an errno is returned
LOG4CXX_WARN_WITH_ERRNO(logger_, "rfcomm Connect failed");
- close(rfcomm_socket); // Always close the socket upon error
+ close(rfcomm_socket); // Always close the socket upon error
if (errno != ECONNREFUSED && errno != ECONNRESET) {
break;
}
diff --git a/src/components/transport_manager/src/tcp/tcp_client_listener.cc b/src/components/transport_manager/src/tcp/tcp_client_listener.cc
index 7a074d9ae9..6458310da8 100644
--- a/src/components/transport_manager/src/tcp/tcp_client_listener.cc
+++ b/src/components/transport_manager/src/tcp/tcp_client_listener.cc
@@ -92,7 +92,8 @@ TransportAdapter::Error TcpClientListener::Init() {
server_address.sin_addr.s_addr = INADDR_ANY;
int optval = 1;
- if (0 != setsockopt(socket_, SOL_SOCKET, SO_REUSEADDR, &optval, sizeof(optval))) {
+ if (0 !=
+ setsockopt(socket_, SOL_SOCKET, SO_REUSEADDR, &optval, sizeof(optval))) {
LOG4CXX_WARN_WITH_ERRNO(logger_, "setsockopt SO_REUSEADDR failed");
}
@@ -150,19 +151,23 @@ void SetKeepaliveOptions(const int fd) {
if (0 != setsockopt(fd, SOL_SOCKET, SO_KEEPALIVE, &yes, sizeof(yes))) {
LOG4CXX_WARN_WITH_ERRNO(logger_, "setsockopt SO_KEEPALIVE failed");
}
- if (0 != setsockopt(fd, IPPROTO_TCP, TCP_KEEPIDLE,
- &keepidle, sizeof(keepidle))) {
+ if (0 !=
+ setsockopt(fd, IPPROTO_TCP, TCP_KEEPIDLE, &keepidle, sizeof(keepidle))) {
LOG4CXX_WARN_WITH_ERRNO(logger_, "setsockopt TCP_KEEPIDLE failed");
}
- if (0 != setsockopt(fd, IPPROTO_TCP, TCP_KEEPCNT, &keepcnt, sizeof(keepcnt))) {
+ if (0 !=
+ setsockopt(fd, IPPROTO_TCP, TCP_KEEPCNT, &keepcnt, sizeof(keepcnt))) {
LOG4CXX_WARN_WITH_ERRNO(logger_, "setsockopt TCP_KEEPCNT failed");
}
- if (0 != setsockopt(fd, IPPROTO_TCP, TCP_KEEPINTVL,
- &keepintvl, sizeof(keepintvl))) {
+ if (0 != setsockopt(
+ fd, IPPROTO_TCP, TCP_KEEPINTVL, &keepintvl, sizeof(keepintvl))) {
LOG4CXX_WARN_WITH_ERRNO(logger_, "setsockopt TCP_KEEPINTVL failed");
}
- if (0 != setsockopt(fd, IPPROTO_TCP, TCP_USER_TIMEOUT,
- &user_timeout, sizeof(user_timeout))) {
+ if (0 != setsockopt(fd,
+ IPPROTO_TCP,
+ TCP_USER_TIMEOUT,
+ &user_timeout,
+ sizeof(user_timeout))) {
LOG4CXX_WARN_WITH_ERRNO(logger_, "setsockopt TCP_USER_TIMEOUT failed");
}
#elif defined(__QNX__) // __linux__
@@ -255,7 +260,8 @@ void TcpClientListener::StopLoop() {
server_address.sin_family = AF_INET;
server_address.sin_port = htons(port_);
server_address.sin_addr.s_addr = INADDR_ANY;
- if (0 != connect(byesocket, reinterpret_cast<sockaddr*>(&server_address),
+ if (0 != connect(byesocket,
+ reinterpret_cast<sockaddr*>(&server_address),
sizeof(server_address))) {
LOG4CXX_WARN_WITH_ERRNO(logger_, "Failed to connect byesocket");
} else {
diff --git a/src/components/utils/src/file_system.cc b/src/components/utils/src/file_system.cc
index 0ae6f973be..947b5b090a 100644
--- a/src/components/utils/src/file_system.cc
+++ b/src/components/utils/src/file_system.cc
@@ -98,8 +98,8 @@ size_t file_system::DirectorySize(const std::string& path) {
size += DirectorySize(full_element_path);
} else {
if (0 != stat(full_element_path.c_str(), &file_info)) {
- LOG4CXX_WARN_WITH_ERRNO(logger_, "Could not get file info: "
- << full_element_path);
+ LOG4CXX_WARN_WITH_ERRNO(
+ logger_, "Could not get file info: " << full_element_path);
} else {
size += file_info.st_size;
}
@@ -271,8 +271,8 @@ void file_system::remove_directory_content(const std::string& directory_name) {
rmdir(full_element_path.c_str());
} else {
if (0 != remove(full_element_path.c_str())) {
- LOG4CXX_WARN_WITH_ERRNO(logger_, "Unable to remove file: "
- << full_element_path);
+ LOG4CXX_WARN_WITH_ERRNO(
+ logger_, "Unable to remove file: " << full_element_path);
}
}
}