summaryrefslogtreecommitdiffstats
path: root/sys/dev/streams
diff options
context:
space:
mode:
Diffstat (limited to 'sys/dev/streams')
-rw-r--r--sys/dev/streams/streams.c10
1 files changed, 1 insertions, 9 deletions
diff --git a/sys/dev/streams/streams.c b/sys/dev/streams/streams.c
index 65fd83a..e303be4 100644
--- a/sys/dev/streams/streams.c
+++ b/sys/dev/streams/streams.c
@@ -198,12 +198,8 @@ streamsopen(struct cdev *dev, int oflags, int devtype, struct thread *td)
int family;
struct proc *p = td->td_proc;
- PROC_LOCK(p);
- if (td->td_dupfd >= 0) {
- PROC_UNLOCK(p);
+ if (td->td_dupfd >= 0)
return ENODEV;
- }
- PROC_UNLOCK(p);
switch (minor(dev)) {
case dev_udp:
@@ -280,9 +276,7 @@ streamsopen(struct cdev *dev, int oflags, int devtype, struct thread *td)
(void)svr4_stream_get(fp);
fdrop(fp, td);
- PROC_LOCK(p);
td->td_dupfd = fd;
- PROC_UNLOCK(p);
return ENXIO;
}
@@ -324,9 +318,7 @@ svr4_ptm_alloc(td)
case ENXIO:
return error;
case 0:
- PROC_LOCK(p);
td->td_dupfd = td->td_retval[0];
- PROC_UNLOCK(p);
return ENXIO;
default:
if (ttynumbers[++n] == '\0') {
OpenPOWER on IntegriCloud