Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

code style only: wrap after open parenthesis if not in one line #24

Merged
merged 1 commit into from
Feb 3, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -139,18 +139,19 @@ rcl_logging_ret_t rcl_logging_external_initialize(
}

char log_name_buffer[512] = {0};
int print_ret = rcutils_snprintf(log_name_buffer, sizeof(log_name_buffer),
"%s/.ros/log/%s_%i_%" PRId64 ".log", homedir, executable_name,
rcutils_get_pid(), ms_since_epoch);
int print_ret = rcutils_snprintf(
log_name_buffer, sizeof(log_name_buffer),
"%s/.ros/log/%s_%i_%" PRId64 ".log", homedir, executable_name,
rcutils_get_pid(), ms_since_epoch);
allocator.deallocate(executable_name, allocator.state);
if (print_ret < 0) {
RCUTILS_SET_ERROR_MSG("Failed to create log file name string");
return RCL_LOGGING_RET_ERROR;
}
std::string log_name_str(log_name_buffer);
LOG4CXX_DECODE_CHAR(log_name_l4cxx_str, log_name_str);
log4cxx::FileAppenderPtr file_appender(new log4cxx::FileAppender(layout, log_name_l4cxx_str,
true));
log4cxx::FileAppenderPtr file_appender(
new log4cxx::FileAppender(layout, log_name_l4cxx_str, true));
root_logger->addAppender(file_appender);
}

Expand Down
7 changes: 4 additions & 3 deletions rcl_logging_spdlog/src/rcl_logging_spdlog.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -135,9 +135,10 @@ rcl_logging_ret_t rcl_logging_external_initialize(
return RCL_LOGGING_RET_ERROR;
}

print_ret = rcutils_snprintf(name_buffer, sizeof(name_buffer),
"%s/.ros/log/%s_%i_%" PRId64 ".log", homedir,
basec, rcutils_get_pid(), ms_since_epoch);
print_ret = rcutils_snprintf(
name_buffer, sizeof(name_buffer),
"%s/.ros/log/%s_%i_%" PRId64 ".log", homedir,
basec, rcutils_get_pid(), ms_since_epoch);
allocator.deallocate(basec, allocator.state);
if (print_ret < 0) {
RCUTILS_SET_ERROR_MSG("Failed to create log file name string");
Expand Down