Module: xenomai-3
Branch: stable-3.0.x
Commit: 0f7aa5af11a345d3226e53660595bbee2db1cf94
URL:    
http://git.xenomai.org/?p=xenomai-3.git;a=commit;h=0f7aa5af11a345d3226e53660595bbee2db1cf94

Author: Philippe Gerum <r...@xenomai.org>
Date:   Fri Mar 18 21:33:36 2016 +0100

lib/cobalt: clear u_window when releasing TSD

---

 lib/cobalt/current.c |    2 ++
 lib/cobalt/umm.c     |    2 +-
 2 files changed, 3 insertions(+), 1 deletion(-)

diff --git a/lib/cobalt/current.c b/lib/cobalt/current.c
index a085456..7d6ee9f 100644
--- a/lib/cobalt/current.c
+++ b/lib/cobalt/current.c
@@ -47,6 +47,7 @@ static inline void __cobalt_set_tsd(xnhandle_t current, __u32 
u_winoff)
 static inline void __cobalt_clear_tsd(void)
 {
        cobalt_current = XN_NO_HANDLE;
+       cobalt_current_window = NULL;
 }
 
 static void init_current_keys(void)
@@ -75,6 +76,7 @@ static inline void __cobalt_set_tsd(xnhandle_t current,
 static inline void __cobalt_clear_tsd(void)
 {
        pthread_setspecific(cobalt_current_key, NULL);
+       pthread_setspecific(cobalt_current_window_key, NULL);
 }
 
 static void init_current_keys(void)
diff --git a/lib/cobalt/umm.c b/lib/cobalt/umm.c
index 5772256..944620f 100644
--- a/lib/cobalt/umm.c
+++ b/lib/cobalt/umm.c
@@ -88,7 +88,7 @@ void cobalt_unmap_umm(void)
         * On machines without an MMU, there is no such thing as fork.
         *
         * We replace former mappings with an invalid one, to detect
-        * any spuriously late access from the fastsync code.
+        * any spurious late access.
         */
        addr = __STD(mmap(cobalt_umm_private,
                          private_size, PROT_NONE,


_______________________________________________
Xenomai-git mailing list
Xenomai-git@xenomai.org
https://xenomai.org/mailman/listinfo/xenomai-git

Reply via email to