Re: [PATCH 4/11] LTTng-core 0.5.108 : core

From: Martin Waitz
Date: Thu Sep 14 2006 - 03:43:52 EST


hoi :)

On Wed, Sep 13, 2006 at 11:43:08PM -0400, Mathieu Desnoyers wrote:
> +int ltt_module_register(enum ltt_module_function name, void *function,
> + struct module *owner)
> +{
> + int ret = 0;
> +
> + /* Protect these operations by disallowing them when tracing is
> + * active */
> + if(ltt_traces.num_active_traces) {
> + ret = -EBUSY;
> + goto end;
> + }

what would happen otherwise?
can it happen that someone enables tracing between this check and
the rest of the function?

> + new_trace->transport = transport;
> + new_trace->ops = &transport->ops;
> +
> + err = -new_trace->ops->create_dirs(new_trace);
^ typo or intentional?


--
Martin Waitz

Attachment: signature.asc
Description: Digital signature