SCCS-vsn: usr.bin/uucp/libacu/vad.c 4.2
-static char sccsid[] = "@(#)vad.c 4.1 (Berkeley) %G%";
+static char sccsid[] = "@(#)vad.c 4.2 (Berkeley) %G%";
#endif
#include "../condevs.h"
#endif
#include "../condevs.h"
DEBUG(4, "%s\n", telno);
for(i = 0; i < 5; ++i) { /* make 5 tries */
/* wake up Vadic */
DEBUG(4, "%s\n", telno);
for(i = 0; i < 5; ++i) { /* make 5 tries */
/* wake up Vadic */
- write(dh, "\005\r", 2);
+ write(dh, "\005", 1);
+ sleep(1);
+ write(dh, "\r", 1);
DEBUG(4, "wanted * ", CNULL);
DEBUG(4, "wanted * ", CNULL);
+ ok = expect("*~5", dh);
DEBUG(4, "got %s\n", ok ? "?" : "that");
if (ok != 0)
continue;
write(dh, "D\r", 2); /* "D" (enter number) command */
DEBUG(4, "wanted NUMBER?\\r\\n ", CNULL);
DEBUG(4, "got %s\n", ok ? "?" : "that");
if (ok != 0)
continue;
write(dh, "D\r", 2); /* "D" (enter number) command */
DEBUG(4, "wanted NUMBER?\\r\\n ", CNULL);
- ok = expect("NUMBER?\r\n", dh);
+ ok = expect("NUMBER?\r\n~5", dh);
DEBUG(4, "got %s\n", ok ? "?" : "that");
if (ok != 0)
continue;
DEBUG(4, "got %s\n", ok ? "?" : "that");
if (ok != 0)
continue;
if (fd > 0) {
close(fd);
sleep(5);
if (fd > 0) {
close(fd);
sleep(5);