summaryrefslogtreecommitdiffstats
path: root/sys/ddb/db_command.c
diff options
context:
space:
mode:
authorrwatson <rwatson@FreeBSD.org>2008-03-07 14:26:30 +0000
committerrwatson <rwatson@FreeBSD.org>2008-03-07 14:26:30 +0000
commit948a982103c551676127bbd82cb20a163a0bb95c (patch)
treea30af4aecbf91e6a279dff7898eb3dbd67672993 /sys/ddb/db_command.c
parent1607c7dea2a74753bb709750676ee6614b1f22fd (diff)
downloadFreeBSD-src-948a982103c551676127bbd82cb20a163a0bb95c.zip
FreeBSD-src-948a982103c551676127bbd82cb20a163a0bb95c.tar.gz
When killing a user process from DDB, check that the requested signal is
> 0 rather than >= 0, or we will panic when trying to deliver the signal. MFC after: 3 days PR: 100802 Submitted by: Valerio Daelli <valerio.daelli at gmail.com>
Diffstat (limited to 'sys/ddb/db_command.c')
-rw-r--r--sys/ddb/db_command.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/sys/ddb/db_command.c b/sys/ddb/db_command.c
index 5ebcc15..db6dc24 100644
--- a/sys/ddb/db_command.c
+++ b/sys/ddb/db_command.c
@@ -599,7 +599,7 @@ db_kill(dummy1, dummy2, dummy3, dummy4)
if (!db_expression(&pid))
DB_ERROR(("Missing process ID\n"));
db_skip_to_eol();
- if (sig < 0 || sig > _SIG_MAXSIG)
+ if (sig < 1 || sig > _SIG_MAXSIG)
DB_ERROR(("Signal number out of range\n"));
/*
OpenPOWER on IntegriCloud