struct ltt_session *session = NULL;
session_lock_list();
- ret_code = session_create(name, geteuid(), getegid(), &session);
+ ret_code = session_create(name, geteuid(), getegid(), NULL, &session);
session_put(session);
if (ret_code == LTTNG_OK) {
/* Validate */
ok(tmp != NULL,
"Destroying session: session found");
- ok(destroy_one_session(tmp) == 0,
- "Destroying session: %s destroyed",
- SESSION1);
+ if (tmp) {
+ ok(destroy_one_session(tmp) == 0,
+ "Destroying session: %s destroyed",
+ SESSION1);
+ } else {
+ skip(1, "Skipping session destruction as it was not found");
+ }
session_unlock_list();
}
const char *expected_session_name_prefix = DEFAULT_SESSION_NAME;
session_lock_list();
- ret_code = session_create(NULL, geteuid(), getegid(), &session);
+ ret_code = session_create(NULL, geteuid(), getegid(), NULL, &session);
ok(ret_code == LTTNG_OK,
"Create session with a NULL name (auto-generate a name)");
if (!session) {