move init of async->events into init_async_buf()
authorFrank Mori Hess <fmhess@speakeasy.net>
Sat, 6 Sep 2003 16:33:54 +0000 (16:33 +0000)
committerFrank Mori Hess <fmhess@speakeasy.net>
Sat, 6 Sep 2003 16:33:54 +0000 (16:33 +0000)
comedi/comedi_fops.c

index b125c89a4c499ef1b385bec050f4a71706ae3eae..49559716f20c015fa7bb3e25195d949527a319e5 100644 (file)
@@ -924,8 +924,6 @@ static int do_cmd_ioctl(comedi_device *dev,void *arg,void *file)
                async->cb_mask |= COMEDI_CB_EOS;
        }
 
-       async->events = 0;
-
        s->runflags=SRF_USER;
 
        s->subdev_flags|=SDF_RUNNING;
@@ -1899,5 +1897,7 @@ static void init_async_buf( comedi_async *async )
        async->cur_chan = 0;
        async->scan_progress = 0;
        async->munge_chan = 0;
+
+       async->events = 0;
 }