[tor-commits] [tor/master] Fix spaces
nickm at torproject.org
nickm at torproject.org
Wed Oct 7 13:34:53 UTC 2015
commit ca927b7f637551746220bea118c036825d440679
Author: Ola Bini <ola at olabini.se>
Date: Mon Oct 5 13:42:43 2015 -0500
Fix spaces
---
src/common/procmon.c | 3 ++-
src/test/log_test_helpers.c | 10 ++++++----
src/test/log_test_helpers.h | 4 +++-
src/test/test_procmon.c | 12 ++++++++----
4 files changed, 19 insertions(+), 10 deletions(-)
diff --git a/src/common/procmon.c b/src/common/procmon.c
index 89c9d75..8c59cad 100644
--- a/src/common/procmon.c
+++ b/src/common/procmon.c
@@ -192,7 +192,8 @@ tor_process_monitor_new(struct event_base *base,
tor_procmon_callback_t cb, void *cb_arg,
const char **msg)
{
- tor_process_monitor_t *procmon = tor_malloc_zero(sizeof(tor_process_monitor_t));
+ tor_process_monitor_t *procmon = tor_malloc_zero(
+ sizeof(tor_process_monitor_t));
struct parsed_process_specifier_t ppspec;
tor_assert(msg != NULL);
diff --git a/src/test/log_test_helpers.c b/src/test/log_test_helpers.c
index 0efa3ce..7dae488 100644
--- a/src/test/log_test_helpers.c
+++ b/src/test/log_test_helpers.c
@@ -37,20 +37,21 @@ const char *
mock_saved_log_at(int ix)
{
int saved_log_count = mock_saved_log_number();
- if(ix < 0) {
+ if (ix < 0) {
ix = saved_log_count + ix;
}
if (saved_log_count <= ix)
return "";
- return ((mock_saved_log_entry_t *)smartlist_get(saved_logs, ix))->generated_msg;
+ return ((mock_saved_log_entry_t *)
+ smartlist_get(saved_logs, ix))->generated_msg;
}
int
mock_saved_severity_at(int ix)
{
int saved_log_count = mock_saved_log_number();
- if(ix < 0) {
+ if (ix < 0) {
ix = saved_log_count + ix;
}
@@ -74,7 +75,8 @@ mock_saved_logs(void)
}
void
-mock_saving_logv(int severity, log_domain_mask_t domain, const char *funcname, const char *suffix, const char *format, va_list ap)
+mock_saving_logv(int severity, log_domain_mask_t domain, const char *funcname,
+ const char *suffix, const char *format, va_list ap)
{
(void)domain;
char *buf = tor_malloc_zero(10240);
diff --git a/src/test/log_test_helpers.h b/src/test/log_test_helpers.h
index debc167..58d14d9 100644
--- a/src/test/log_test_helpers.h
+++ b/src/test/log_test_helpers.h
@@ -15,7 +15,9 @@ typedef struct mock_saved_log_entry_t {
struct mock_saved_log_entry_t *next;
} mock_saved_log_entry_t;
-void mock_saving_logv(int severity, log_domain_mask_t domain, const char *funcname, const char *suffix, const char *format, va_list ap);
+void mock_saving_logv(int severity, log_domain_mask_t domain,
+ const char *funcname, const char *suffix,
+ const char *format, va_list ap);
void mock_clean_saved_logs(void);
const smartlist_t *mock_saved_logs(void);
int setup_capture_of_logs(int new_level);
diff --git a/src/test/test_procmon.c b/src/test/test_procmon.c
index ac70a0f..6a9c209 100644
--- a/src/test/test_procmon.c
+++ b/src/test/test_procmon.c
@@ -29,15 +29,18 @@ test_procmon_tor_process_monitor_new(void *ignored)
tt_assert(!res);
tt_str_op(msg, OP_EQ, "invalid PID");
- res = tor_process_monitor_new(tor_libevent_get_base(), "43", 0, NULL, NULL, &msg);
+ res = tor_process_monitor_new(tor_libevent_get_base(), "43", 0,
+ NULL, NULL, &msg);
tt_assert(res);
tt_assert(!msg);
- res = tor_process_monitor_new(tor_libevent_get_base(), "44 hello", 0, NULL, NULL, &msg);
+ res = tor_process_monitor_new(tor_libevent_get_base(), "44 hello", 0,
+ NULL, NULL, &msg);
tt_assert(res);
tt_assert(!msg);
- res = tor_process_monitor_new(tor_libevent_get_base(), "45:hello", 0, NULL, NULL, &msg);
+ res = tor_process_monitor_new(tor_libevent_get_base(), "45:hello", 0,
+ NULL, NULL, &msg);
tt_assert(res);
tt_assert(!msg);
@@ -46,6 +49,7 @@ test_procmon_tor_process_monitor_new(void *ignored)
}
struct testcase_t procmon_tests[] = {
- { "tor_process_monitor_new", test_procmon_tor_process_monitor_new, TT_FORK, NULL, NULL },
+ { "tor_process_monitor_new", test_procmon_tor_process_monitor_new,
+ TT_FORK, NULL, NULL },
END_OF_TESTCASES
};
More information about the tor-commits
mailing list