From: Mathieu Desnoyers Date: Thu, 2 May 2013 17:48:48 +0000 (-0400) Subject: lttng UI: round up trace file size to subbuf size if needed X-Git-Tag: v2.2.0-rc2~11 X-Git-Url: https://git.lttng.org/?p=lttng-tools.git;a=commitdiff_plain;h=de65565af61d60ddad1b309c969d6a2129ba4f19;hp=1cb514cec8d71a17376a1f2e78f0a68f2f410521 lttng UI: round up trace file size to subbuf size if needed Signed-off-by: Mathieu Desnoyers --- diff --git a/src/bin/lttng/commands/enable_channels.c b/src/bin/lttng/commands/enable_channels.c index 0894f051b..4816d62c6 100644 --- a/src/bin/lttng/commands/enable_channels.c +++ b/src/bin/lttng/commands/enable_channels.c @@ -208,11 +208,9 @@ static int enable_channel(char *session_name) if ((chan.attr.tracefile_size > 0) && (chan.attr.tracefile_size < chan.attr.subbuf_size)) { - ERR("Tracefile_size must be greater than or equal to subbuf_size " - "(%" PRIu64 " < %" PRIu64 ")", + WARN("Tracefile size rounded up from (%" PRIu64 ") to subbuffer size (%" PRIu64 ")", chan.attr.tracefile_size, chan.attr.subbuf_size); - ret = CMD_ERROR; - goto error; + chan.attr.tracefile_size = chan.attr.subbuf_size; } /* Setting channel output */