+
+ /* Start autoflush while waiting for dump schedule */
+ if(!nodump) {
+ /* Start any autoflush tape writes */
+ if (!empty(tapeq)) {
+ startaflush();
+ short_dump_state(); /* for amstatus */
+
+ /* Process taper results until the schedule arrives */
+ while (1) {
+ FD_ZERO(&selectset);
+ FD_SET(0, &selectset);
+ FD_SET(taper, &selectset);
+
+ if(select(taper+1, (SELECT_ARG_TYPE *)(&selectset), NULL, NULL,
+ &sleep_time) == -1)
+ error("select: %s", strerror(errno));
+ if (FD_ISSET(0, &selectset)) break; /* schedule arrived */
+ if (FD_ISSET(taper, &selectset)) handle_taper_result();
+ short_dump_state(); /* for amstatus */
+ }
+
+ }
+
+ /* Read the dump schedule */
+ read_schedule(&waitq, &runq);
+ }
+
+ /* Start any needed flushes */