X-Git-Url: https://git.lttng.org/?p=lttng-tools.git;a=blobdiff_plain;f=src%2Fbin%2Flttng-sessiond%2Fust-app.c;h=9ab5f77e0067b8f129b8ce4e17c2bba12d386f43;hp=3abd12716818b4aa60a95b35869c19ea89b137ac;hb=57703f6e0047955a0c68829630fcc42aad988a39;hpb=e64207cf612a1e1a34131427b7cea17ce82ea091 diff --git a/src/bin/lttng-sessiond/ust-app.c b/src/bin/lttng-sessiond/ust-app.c index 3abd12716..9ab5f77e0 100644 --- a/src/bin/lttng-sessiond/ust-app.c +++ b/src/bin/lttng-sessiond/ust-app.c @@ -3438,11 +3438,21 @@ void ust_app_clean_list(void) /* * Init UST app hash table. */ -void ust_app_ht_alloc(void) +int ust_app_ht_alloc(void) { ust_app_ht = lttng_ht_new(0, LTTNG_HT_TYPE_ULONG); + if (!ust_app_ht) { + return -1; + } ust_app_ht_by_sock = lttng_ht_new(0, LTTNG_HT_TYPE_ULONG); + if (!ust_app_ht_by_sock) { + return -1; + } ust_app_ht_by_notify_sock = lttng_ht_new(0, LTTNG_HT_TYPE_ULONG); + if (!ust_app_ht_by_notify_sock) { + return -1; + } + return 0; } /*