]> git.pond.sub.org Git - empserver/commitdiff
io_shutdown() is now unused, remove
authorMarkus Armbruster <armbru@pond.sub.org>
Sun, 18 Mar 2012 18:04:21 +0000 (19:04 +0100)
committerMarkus Armbruster <armbru@pond.sub.org>
Thu, 26 Apr 2012 17:57:19 +0000 (19:57 +0200)
include/empio.h
src/lib/empthread/io.c

index 0dbf9af29b557f8b574bb711552a22413a2b4260..ab47fdf0c57cb637bda0badfd68ba9a57679399f 100644 (file)
@@ -54,7 +54,6 @@ extern int io_read(struct iop *, char *, int);
 extern int io_write(struct iop *, char *, int);
 extern int io_gets(struct iop *, char *, int);
 extern int io_puts(struct iop *, char *);
-extern int io_shutdown(struct iop *, int);
 extern int io_error(struct iop *);
 extern int io_eof(struct iop *);
 extern void io_set_eof(struct iop *);
index 0a44916d7462da0cf1ec502268775e1d0ff2713b..6578c29561002b9d17b85240fed1243eec3716b1 100644 (file)
@@ -352,24 +352,6 @@ io_puts(struct iop *iop, char *buf)
     return ioq_puts(iop->output, buf);
 }
 
-int
-io_shutdown(struct iop *iop, int flags)
-{
-    flags &= (IO_READ | IO_WRITE);
-    if ((iop->flags & flags) != flags)
-       return -1;
-    if (flags & IO_READ) {
-       shutdown(iop->fd, 0);
-       ioq_drain(iop->input);
-    }
-    if (flags & IO_WRITE) {
-       shutdown(iop->fd, 1);
-       ioq_drain(iop->output);
-       iop->last_out = 0;
-    }
-    return 0;
-}
-
 int
 io_error(struct iop *iop)
 {