Disable security key for bigendian interop.
[openssh.git] / platform-listen.c
blob42c4040f0c8133ee1278929108886a38f61db3b5
1 /*
2 * Copyright (c) 2006 Darren Tucker. All rights reserved.
4 * Permission to use, copy, modify, and distribute this software for any
5 * purpose with or without fee is hereby granted, provided that the above
6 * copyright notice and this permission notice appear in all copies.
8 * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
9 * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
10 * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
11 * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
12 * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
13 * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
14 * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
17 #include "includes.h"
19 #include <stdarg.h>
20 #include <stdio.h>
21 #include <string.h>
22 #include <unistd.h>
24 #include "log.h"
25 #include "misc.h"
26 #include "platform.h"
28 #include "openbsd-compat/openbsd-compat.h"
30 void
31 platform_pre_listen(void)
33 #ifdef LINUX_OOM_ADJUST
34 /* Adjust out-of-memory killer so listening process is not killed */
35 oom_adjust_setup();
36 #endif
39 void
40 platform_post_listen(void)
42 #ifdef SYSTEMD_NOTIFY
43 ssh_systemd_notify_ready();
44 #endif
47 void
48 platform_pre_fork(void)
50 #ifdef USE_SOLARIS_PROCESS_CONTRACTS
51 solaris_contract_pre_fork();
52 #endif
55 void
56 platform_pre_restart(void)
58 #ifdef SYSTEMD_NOTIFY
59 ssh_systemd_notify_reload();
60 #endif
61 #ifdef LINUX_OOM_ADJUST
62 oom_adjust_restore();
63 #endif
66 void
67 platform_post_fork_parent(pid_t child_pid)
69 #ifdef USE_SOLARIS_PROCESS_CONTRACTS
70 solaris_contract_post_fork_parent(child_pid);
71 #endif
74 void
75 platform_post_fork_child(void)
77 #ifdef USE_SOLARIS_PROCESS_CONTRACTS
78 solaris_contract_post_fork_child();
79 #endif
80 #ifdef LINUX_OOM_ADJUST
81 oom_adjust_restore();
82 #endif