Re: [PATCH v8 08/14] perf tools: Extract common API out of unwind-libunwind-local.c

From: Jiri Olsa
Date: Thu Jun 02 2016 - 16:34:46 EST


On Thu, Jun 02, 2016 at 09:55:20AM +0000, He Kuang wrote:

SNIP

> +void unwind__finish_access(struct thread *thread)
> +{
> + if (thread->unwind_libunwind_ops)
> + thread->unwind_libunwind_ops->finish_access(thread);
> +}
> +
> +int unwind__get_entries(unwind_entry_cb_t cb, void *arg,
> + struct thread *thread,
> + struct perf_sample *data, int max_stack)
> +{
> + if (thread->unwind_libunwind_ops)
> + return thread->unwind_libunwind_ops->get_entries(cb, arg,
> + thread,
> + data,
> + max_stack);

please enclose both if and else paths into { }
there's a rule to do that for multiple line paths

thanks,
jirka