Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/kern ptrace_Common is a module unto itself. Don't use t...
details: https://anonhg.NetBSD.org/src/rev/1abd3f976711
branches: trunk
changeset: 977505:1abd3f976711
user: pgoyette <pgoyette%NetBSD.org@localhost>
date: Sun Oct 25 15:55:36 2020 +0000
description:
ptrace_Common is a module unto itself. Don't use the ptrace module's
init/fini routines.
diffstat:
sys/kern/sys_ptrace_common.c | 22 ++++++++++++++++++----
1 files changed, 18 insertions(+), 4 deletions(-)
diffs (51 lines):
diff -r aba19934f45c -r 1abd3f976711 sys/kern/sys_ptrace_common.c
--- a/sys/kern/sys_ptrace_common.c Sun Oct 25 15:49:03 2020 +0000
+++ b/sys/kern/sys_ptrace_common.c Sun Oct 25 15:55:36 2020 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: sys_ptrace_common.c,v 1.87 2020/10/20 20:28:55 christos Exp $ */
+/* $NetBSD: sys_ptrace_common.c,v 1.88 2020/10/25 15:55:36 pgoyette Exp $ */
/*-
* Copyright (c) 2008, 2009 The NetBSD Foundation, Inc.
@@ -107,7 +107,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: sys_ptrace_common.c,v 1.87 2020/10/20 20:28:55 christos Exp $");
+__KERNEL_RCSID(0, "$NetBSD: sys_ptrace_common.c,v 1.88 2020/10/25 15:55:36 pgoyette Exp $");
#ifdef _KERNEL_OPT
#include "opt_ptrace.h"
@@ -1577,16 +1577,30 @@
MODULE(MODULE_CLASS_EXEC, ptrace_common, NULL);
static int
+ptrace_common_init(void)
+{
+
+ return 0;
+}
+
+static int
+ptrace_common_fini(void)
+{
+
+ return 0;
+}
+
+static int
ptrace_common_modcmd(modcmd_t cmd, void *arg)
{
int error;
switch (cmd) {
case MODULE_CMD_INIT:
- error = ptrace_init();
+ error = ptrace_common_init();
break;
case MODULE_CMD_FINI:
- error = ptrace_fini();
+ error = ptrace_common_fini();
break;
default:
ptrace_hooks();
Home |
Main Index |
Thread Index |
Old Index