Is there any actual reason for these restrictions ?

I can understanding preventing stuff if it breaks, but I don't think
it does ?

Index: sio.c
===================================================================
RCS file: /home/openbsd/cvs/src/lib/libsndio/sio.c,v
retrieving revision 1.10
diff -u -p -r1.10 sio.c
--- sio.c       23 May 2012 19:25:11 -0000      1.10
+++ sio.c       19 Aug 2012 10:32:53 -0000
@@ -174,11 +174,6 @@ sio_getpar(struct sio_hdl *hdl, struct s
                DPRINTF("sio_getpar: eof\n");
                return 0;
        }
-       if (hdl->started) {
-               DPRINTF("sio_getpar: already started\n");
-               hdl->eof = 1;
-               return 0;
-       }
        if (!hdl->ops->getpar(hdl, par)) {
                par->__magic = 0;
                return 0;
@@ -385,11 +380,6 @@ sio_eof(struct sio_hdl *hdl)
 void
 sio_onmove(struct sio_hdl *hdl, void (*cb)(void *, int), void *addr)
 {
-       if (hdl->started) {
-               DPRINTF("sio_onmove: already started\n");
-               hdl->eof = 1;
-               return;
-       }
        hdl->move_cb = cb;
        hdl->move_addr = addr;
 }
@@ -437,11 +427,6 @@ sio_setvol(struct sio_hdl *hdl, unsigned
 int
 sio_onvol(struct sio_hdl *hdl, void (*cb)(void *, unsigned int), void *addr)
 {
-       if (hdl->started) {
-               DPRINTF("sio_onvol: already started\n");
-               hdl->eof = 1;
-               return 0;
-       }
        if (!hdl->ops->setvol)
                return 0;
        hdl->vol_cb = cb;

Reply via email to