Deleted Added
sdiff udiff text old ( 202341 ) new ( 215664 )
full compact
1/*-
2 * Copyright (c) 2002 Doug Rabson
3 * Copyright (c) 1994-1995 S�ren Schmidt
4 * All rights reserved.
5 *
6 * Redistribution and use in source and binary forms, with or without
7 * modification, are permitted provided that the following conditions
8 * are met:

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

23 * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
24 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
25 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
26 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
27 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
28 */
29
30#include <sys/cdefs.h>
31__FBSDID("$FreeBSD: head/sys/compat/linux/linux_misc.c 215664 2010-11-22 09:06:59Z netchild $");
32
33#include "opt_compat.h"
34
35#include <sys/param.h>
36#include <sys/blist.h>
37#include <sys/fcntl.h>
38#if defined(__i386__)
39#include <sys/imgact_aout.h>

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

1690 name[1] = KERN_NISDOMAINNAME;
1691 return (userland_sysctl(td, name, 2, 0, 0, 0, args->name,
1692 args->len, 0, 0));
1693}
1694
1695int
1696linux_exit_group(struct thread *td, struct linux_exit_group_args *args)
1697{
1698 struct linux_emuldata *em;
1699
1700#ifdef DEBUG
1701 if (ldebug(exit_group))
1702 printf(ARGS(exit_group, "%i"), args->error_code);
1703#endif
1704
1705 em = em_find(td->td_proc, EMUL_DONTLOCK);
1706 if (em->shared->refs > 1) {
1707 EMUL_SHARED_WLOCK(&emul_shared_lock);
1708 em->shared->flags |= EMUL_SHARED_HASXSTAT;
1709 em->shared->xstat = W_EXITCODE(args->error_code, 0);
1710 EMUL_SHARED_WUNLOCK(&emul_shared_lock);
1711 if (linux_use26(td))
1712 linux_kill_threads(td, SIGKILL);
1713 }
1714
1715 /*
1716 * XXX: we should send a signal to the parent if
1717 * SIGNAL_EXIT_GROUP is set. We ignore that (temporarily?)
1718 * as it doesnt occur often.
1719 */
1720 exit1(td, W_EXITCODE(args->error_code, 0));
1721
1722 return (0);

--- 135 unchanged lines hidden ---