Deleted Added
full compact
thr_exit.c (144518) thr_exit.c (144921)
1/*
2 * Copyright (c) 1995-1998 John Birrell <jb@cimlogic.com.au>
3 * All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 * 1. Redistributions of source code must retain the above copyright

--- 15 unchanged lines hidden (view full) ---

24 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
25 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
26 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
27 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
28 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
29 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
30 * SUCH DAMAGE.
31 *
1/*
2 * Copyright (c) 1995-1998 John Birrell <jb@cimlogic.com.au>
3 * All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 * 1. Redistributions of source code must retain the above copyright

--- 15 unchanged lines hidden (view full) ---

24 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
25 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
26 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
27 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
28 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
29 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
30 * SUCH DAMAGE.
31 *
32 * $FreeBSD: head/lib/libthr/thread/thr_exit.c 144518 2005-04-02 01:20:00Z davidxu $
32 * $FreeBSD: head/lib/libthr/thread/thr_exit.c 144921 2005-04-12 03:00:28Z davidxu $
33 */
34
35#include <errno.h>
36#include <stdio.h>
37#include <stdlib.h>
38#include <pthread.h>
39
40#include "thr_private.h"

--- 84 unchanged lines hidden (view full) ---

125 /* Never reach! */
126 }
127 if (curthread->tlflags & TLFLAGS_DETACHED)
128 THR_GCLIST_ADD(curthread);
129 curthread->state = PS_DEAD;
130 THREAD_LIST_UNLOCK(curthread);
131 if (curthread->joiner)
132 _thr_umtx_wake(&curthread->state, INT_MAX);
33 */
34
35#include <errno.h>
36#include <stdio.h>
37#include <stdlib.h>
38#include <pthread.h>
39
40#include "thr_private.h"

--- 84 unchanged lines hidden (view full) ---

125 /* Never reach! */
126 }
127 if (curthread->tlflags & TLFLAGS_DETACHED)
128 THR_GCLIST_ADD(curthread);
129 curthread->state = PS_DEAD;
130 THREAD_LIST_UNLOCK(curthread);
131 if (curthread->joiner)
132 _thr_umtx_wake(&curthread->state, INT_MAX);
133 thr_exit(&curthread->terminated);
133 if (SHOULD_REPORT_EVENT(curthread, TD_DEATH))
134 _thr_report_death(curthread);
135 thr_exit(&curthread->tid);
134 PANIC("thr_exit() returned");
135 /* Never reach! */
136}
136 PANIC("thr_exit() returned");
137 /* Never reach! */
138}