diff options
author | Greg Lehey <grog@FreeBSD.org> | 2002-01-27 04:20:52 +0000 |
---|---|---|
committer | Greg Lehey <grog@FreeBSD.org> | 2002-01-27 04:20:52 +0000 |
commit | 98912ee8cc9017b6a85f32e58229cbdf91b05d0e (patch) | |
tree | f7ea455638009ce29ad657a97813cd4b23577304 | |
parent | 3bf31598f809509958cdeb65d7dfde543034b39c (diff) | |
download | src-98912ee8cc9017b6a85f32e58229cbdf91b05d0e.tar.gz src-98912ee8cc9017b6a85f32e58229cbdf91b05d0e.zip |
vinumioctl: Fix a double fault caused by calling setjmp() without holding the config lock. The call was in fact superfluous.
Notes
Notes:
svn path=/head/; revision=89842
-rw-r--r-- | sys/dev/vinum/vinumconfig.c | 2 | ||||
-rw-r--r-- | sys/dev/vinum/vinumioctl.c | 3 |
2 files changed, 2 insertions, 3 deletions
diff --git a/sys/dev/vinum/vinumconfig.c b/sys/dev/vinum/vinumconfig.c index fea3c2fc89a8..e1d7d0efeaae 100644 --- a/sys/dev/vinum/vinumconfig.c +++ b/sys/dev/vinum/vinumconfig.c @@ -99,6 +99,8 @@ throw_rude_remark(int error, char *msg,...) static int finishing; /* don't recurse */ int was_finishing; + if ((vinum_conf.flags & VF_LOCKED) == 0) /* bug catcher */ + panic ("throw_rude_remark: called without config lock"); va_start(ap, msg); if ((ioctl_reply != NULL) /* we're called from the user */ &&(!(vinum_conf.flags & VF_READING_CONFIG))) { /* and not reading from disk: return msg */ diff --git a/sys/dev/vinum/vinumioctl.c b/sys/dev/vinum/vinumioctl.c index 7abfe115c264..94a9790b4cbe 100644 --- a/sys/dev/vinum/vinumioctl.c +++ b/sys/dev/vinum/vinumioctl.c @@ -82,9 +82,6 @@ vinumioctl(dev_t dev, switch (DEVTYPE(dev)) { case VINUM_SUPERDEV_TYPE: /* ordinary super device */ ioctl_reply = (struct _ioctl_reply *) data; /* save the address to reply to */ - error = setjmp(command_fail); /* come back here on error */ - if (error) /* bombed out */ - return 0; /* the reply will contain meaningful info */ switch (cmd) { #ifdef VINUMDEBUG case VINUM_DEBUG: |