X-Git-Url: https://git.lttng.org/?p=lttng-tools.git;a=blobdiff_plain;f=src%2Fbin%2Flttng%2Fcommands%2Fsnapshot.c;h=298bc6ef36cee6a1bac7cb362464c0dd22f9915c;hp=abdf1890198b1653a2a3a2ab0bc5bc0599d584aa;hb=dad01b0a32248a3accec24e763b354610321d228;hpb=1b7c93cbef5f1c0497f65c9b48b3487e1f6c6034 diff --git a/src/bin/lttng/commands/snapshot.c b/src/bin/lttng/commands/snapshot.c index abdf18901..298bc6ef3 100644 --- a/src/bin/lttng/commands/snapshot.c +++ b/src/bin/lttng/commands/snapshot.c @@ -725,6 +725,15 @@ int cmd_snapshot(int argc, const char **argv) break; case LTTNG_ERR_SNAPSHOT_NODATA: WARN("%s", lttng_strerror(command_ret)); + + /* A warning is fine since the user has no control on + * whether or not applications (or the kernel) have + * produced any event between the start of the tracing + * session and the recording of the snapshot. MI wise + * the command is not a success since nothing was + * recorded. + */ + command_ret = 0; break; default: ERR("%s", lttng_strerror(command_ret));