Deleted Added
full compact
sigev_thread.c (156142) sigev_thread.c (156192)
1/*
2 * Copyright (c) 2005 David Xu <davidxu@freebsd.org>
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

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

18 * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
19 * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
20 * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
21 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
22 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
23 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
24 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
25 *
1/*
2 * Copyright (c) 2005 David Xu <davidxu@freebsd.org>
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

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

18 * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
19 * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
20 * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
21 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
22 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
23 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
24 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
25 *
26 * $FreeBSD: head/lib/librt/sigev_thread.c 156142 2006-03-01 08:50:36Z davidxu $
26 * $FreeBSD: head/lib/librt/sigev_thread.c 156192 2006-03-01 23:38:53Z davidxu $
27 *
28 */
29
30#include <sys/types.h>
31#include <machine/atomic.h>
32
33#include "namespace.h"
34#include <err.h>

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

412 __sigev_list_lock();
413 sn = __sigev_find(si.si_code, id);
414 if (sn != NULL) {
415 tn->tn_cur = sn;
416 sn->sn_flags |= SNF_WORKING;
417 __sigev_list_unlock();
418 sn->sn_dispatch(sn, &si);
419 after_dispatch(tn);
27 *
28 */
29
30#include <sys/types.h>
31#include <machine/atomic.h>
32
33#include "namespace.h"
34#include <err.h>

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

412 __sigev_list_lock();
413 sn = __sigev_find(si.si_code, id);
414 if (sn != NULL) {
415 tn->tn_cur = sn;
416 sn->sn_flags |= SNF_WORKING;
417 __sigev_list_unlock();
418 sn->sn_dispatch(sn, &si);
419 after_dispatch(tn);
420 } else
420 } else {
421 tn->tn_cur = NULL;
421 tn->tn_cur = NULL;
422 __sigev_list_unlock();
422 __sigev_list_unlock();
423 }
423 }
424 pthread_cleanup_pop(0);
425 return (0);
426}
424 }
425 pthread_cleanup_pop(0);
426 return (0);
427}