projects
/
lttng-ust.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Fix: Don't wait during registration if clock_gettime() fails
[lttng-ust.git]
/
liblttng-ust
/
lttng-ust-comm.c
diff --git
a/liblttng-ust/lttng-ust-comm.c
b/liblttng-ust/lttng-ust-comm.c
index 378ca21cfc71f354a282fe4a9a521cf77319ef02..f40683d37c306fc3157de9793a258d4f58e0f3fe 100644
(file)
--- a/
liblttng-ust/lttng-ust-comm.c
+++ b/
liblttng-ust/lttng-ust-comm.c
@@
-399,7
+399,7
@@
int setup_local_apps(void)
/*
* Get notify_sock timeout, in ms.
/*
* Get notify_sock timeout, in ms.
- * -1:
don't wait. 0: wait forever
. >0: timeout, in ms.
+ * -1:
wait forever. 0: don't wait
. >0: timeout, in ms.
*/
static
long get_timeout(void)
*/
static
long get_timeout(void)
@@
-422,7
+422,7
@@
long get_notify_sock_timeout(void)
}
/*
}
/*
- * Return values: -1:
don't wait. 0: wait forever
. 1: timeout wait.
+ * Return values: -1:
wait forever. 0: don't wait
. 1: timeout wait.
*/
static
int get_constructor_timeout(struct timespec *constructor_timeout)
*/
static
int get_constructor_timeout(struct timespec *constructor_timeout)
@@
-445,7
+445,8
@@
int get_constructor_timeout(struct timespec *constructor_timeout)
*/
ret = clock_gettime(CLOCK_REALTIME, constructor_timeout);
if (ret) {
*/
ret = clock_gettime(CLOCK_REALTIME, constructor_timeout);
if (ret) {
- return -1;
+ /* Don't wait. */
+ return 0;
}
constructor_timeout->tv_sec += constructor_delay_ms / 1000UL;
constructor_timeout->tv_nsec +=
}
constructor_timeout->tv_sec += constructor_delay_ms / 1000UL;
constructor_timeout->tv_nsec +=
@@
-454,6
+455,7
@@
int get_constructor_timeout(struct timespec *constructor_timeout)
constructor_timeout->tv_sec++;
constructor_timeout->tv_nsec -= 1000000000UL;
}
constructor_timeout->tv_sec++;
constructor_timeout->tv_nsec -= 1000000000UL;
}
+ /* Timeout wait (constructor_delay_ms). */
return 1;
}
return 1;
}
This page took
0.023922 seconds
and
4
git commands to generate.