static int parse_args(int argc, char **argv)
{
int opt, ret;
+ char *user;
if (argc < 2) {
usage(stderr);
goto error;
}
+ /* For Mathieu Desnoyers a.k.a. Dr. Tracing */
+ user = getenv("USER");
+ if (user != NULL && ((strncmp(progname, "drtrace", 7) == 0 ||
+ strncmp("compudj", user, 7) == 0))) {
+ MSG("%c[%d;%dmWelcome back Dr Tracing!%c[%dm\n", 27,1,33,27,0);
+ }
+ /* Thanks Mathieu */
+
/*
* Handle leftovers which is a first level command with the trailing
* options.
int main(int argc, char *argv[])
{
int ret;
- char *user;
progname = argv[0] ? argv[0] : "lttng";
- /* For Mathieu Desnoyers a.k.a. Dr. Tracing */
- user = getenv("USER");
- if (user != NULL && ((strncmp(progname, "drtrace", 7) == 0 ||
- strncmp("compudj", user, 7) == 0))) {
- MSG("%c[%d;%dmWelcome back Dr Tracing!%c[%dm\n", 27,1,33,27,0);
- }
- /* Thanks Mathieu */
-
ret = set_signal_handler();
if (ret < 0) {
clean_exit(ret);