commit 951638a06d20263d33e501bdfa317c34b850f2b8
Author: Nick Mathewson <nickm(a)torproject.org>
Date: Sat Sep 24 09:12:00 2016 -0700
Fix pthread_cond_timedwait() on OSX Sierra
Sierra provides clock_gettime(), but not pthread_condattr_setclock.
So we had better lot try to use CLOCK_MONOTONIC as our source for
time when waiting, since we ccan never actually tell the condition
that we mean CLOCK_MONOTONIC.
This isn't a tor bug yet, since we never actually …
[View More]pass a timeout to
tor_cond_wait() outside of the unit tests.
---
src/common/compat_pthreads.c | 17 ++++++++++++-----
1 file changed, 12 insertions(+), 5 deletions(-)
diff --git a/src/common/compat_pthreads.c b/src/common/compat_pthreads.c
index 7640eba..4c05676 100644
--- a/src/common/compat_pthreads.c
+++ b/src/common/compat_pthreads.c
@@ -192,14 +192,21 @@ tor_cond_init(tor_cond_t *cond)
return -1;
}
-#if defined(HAVE_CLOCK_GETTIME) && defined(CLOCK_MONOTONIC) \
- && defined(HAVE_PTHREAD_CONDATTR_SETCLOCK)
+#if defined(HAVE_CLOCK_GETTIME)
+#if defined(CLOCK_MONOTONIC) && defined(HAVE_PTHREAD_CONDATTR_SETCLOCK)
/* Use monotonic time so when we timedwait() on it, any clock adjustment
* won't affect the timeout value. */
if (pthread_condattr_setclock(&condattr, CLOCK_MONOTONIC)) {
return -1;
}
-#endif
+#define USE_COND_CLOCK CLOCK_MONOTONIC
+#else /* !defined HAVE_PTHREAD_CONDATTR_SETCLOCK */
+ /* On OSX Sierra, there is no pthread_condattr_setclock, so we are stuck
+ * with the realtime clock.
+ */
+#define USE_COND_CLOCK CLOCK_REALTIME
+#endif /* which clock to use */
+#endif /* HAVE_CLOCK_GETTIME */
if (pthread_cond_init(&cond->cond, &condattr)) {
return -1;
}
@@ -242,8 +249,8 @@ tor_cond_wait(tor_cond_t *cond, tor_mutex_t *mutex, const struct timeval *tv)
struct timeval tvnow, tvsum;
struct timespec ts;
while (1) {
-#if defined(HAVE_CLOCK_GETTIME) && defined(CLOCK_MONOTONIC)
- if (clock_gettime(CLOCK_MONOTONIC, &ts) < 0) {
+#if defined(HAVE_CLOCK_GETTIME) && defined(USE_COND_CLOCK)
+ if (clock_gettime(USE_COND_CLOCK, &ts) < 0) {
return -1;
}
tvnow.tv_sec = ts.tv_sec;
[View Less]
commit 721676497af1a05d0fbb1b34cd0a291f12f9f8a5
Author: Translation commit bot <translation(a)torproject.org>
Date: Sat Sep 24 19:17:50 2016 +0000
Update translations for tor-messenger-ircproperties
---
la/irc.properties | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/la/irc.properties b/la/irc.properties
index 75f9863..748fe9e 100644
--- a/la/irc.properties
+++ b/la/irc.properties
@@ -47,7 +47,7 @@ ctcp.time=The time for %1$S is %2$S.
# These are the help …
[View More]messages for each command, the %S is the command name
# Each command first gives the parameter it accepts and then a description of
# the command.
-command.action=%S <action to perform>: Perform an action.
+command.action=%S <actio agendo>: Actionem agere
command.ctcp=%S <nick> <msg>: Sends a CTCP message to the nick.
command.chanserv=%S <command>: Send a command to ChanServ.
command.deop=%S <nick1>[,<nick2>]*: Remove channel operator status from someone. You must be a channel operator to do this.
[View Less]
commit 4685b1b7bbf9ec3d55f06753bfea2486e3f16571
Author: Translation commit bot <translation(a)torproject.org>
Date: Sat Sep 24 18:47:52 2016 +0000
Update translations for tor-messenger-ircproperties
---
la/irc.properties | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/la/irc.properties b/la/irc.properties
index c2f398a..75f9863 100644
--- a/la/irc.properties
+++ b/la/irc.properties
@@ -60,7 +60,7 @@ command.memoserv=%S <command>: Send a …
[View More]command to MemoServ.
command.modeUser=%S (+|-)<new mode> [<nick>]: Set or unset a user's mode.
command.modeChannel=%S <channel>[ (+|-)<new mode> [<parameter>][,<parameter>]*]: Get, set or unset a channel mode.
command.msg=%S <nick> <message>: Send a private message to a user (as opposed to a channel).
-command.nick=%S <new nickname>: Change your nickname.
+command.nick=%S <nomen novum>: Nomen mutare
command.nickserv=%S <command>: Send a command to NickServ.
command.notice=%S <target> <message>: Send a notice to a user or channel.
command.op=%S <nick1>[,<nick2>]*: Grant channel operator status to someone. You must be a channel operator to do this.
@@ -80,7 +80,7 @@ command.whois2=%S [<nick>]: Get information on a user.
# These are shown as system messages in the conversation.
# %1$S is the nick and %2$S is the nick and host of the user who joined.
message.join=%1$S [%2$S] entered the room.
-message.rejoined=You have rejoined the room.
+message.rejoined=Spatium inisti.
# %1$S is the nick of who kicked you.
# %2$S is message.kicked.reason, if a kick message was given.
message.kicked.you=You have been kicked by %1$S%2$S.
[View Less]
commit 848f635c92d5635ccea0b1c8f5b3dcf728e60c82
Author: Translation commit bot <translation(a)torproject.org>
Date: Sat Sep 24 18:47:45 2016 +0000
Update translations for tor-messenger-imtooltipproperties
---
la/imtooltip.properties | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/la/imtooltip.properties b/la/imtooltip.properties
index 0dd51fe..6065ba2 100644
--- a/la/imtooltip.properties
+++ b/la/imtooltip.properties
@@ -2,6 +2,6 @@
# License, v. 2.0. If a …
[View More]copy of the MPL was not distributed with this
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
-buddy.username=Username
+buddy.username=Nomen usatoris
buddy.account=Account
contact.tags=Tags
[View Less]