Fix strcmp duplicates iun ftdx simulators

pull/1265/head
Mike Black W9MDB 2023-03-26 17:03:27 -05:00
rodzic d522967b32
commit d34983f495
3 zmienionych plików z 0 dodań i 91 usunięć

Wyświetl plik

@ -157,16 +157,6 @@ int main(int argc, char *argv[])
if (n <= 0) { perror("ID"); }
}
else if (strcmp(buf, "AI;") == 0)
{
printf("%s\n", buf);
usleep(50 * 1000);
SNPRINTF(buf, sizeof(buf), "AI0;");
n = write(fd, buf, strlen(buf));
printf("n=%d\n", n);
if (n <= 0) { perror("ID"); }
}
#if 0
else if (strncmp(buf, "AI", 2) == 0)
@ -183,16 +173,6 @@ int main(int argc, char *argv[])
}
#endif
else if (strcmp(buf, "VS;") == 0)
{
printf("%s\n", buf);
usleep(50 * 1000);
pbuf = "VS0;";
n = write(fd, pbuf, strlen(pbuf));
printf("n=%d\n", n);
if (n < 0) { perror("VS"); }
}
else if (strcmp(buf, "EX032;") == 0)
{
static int ant = 0;

Wyświetl plik

@ -157,42 +157,7 @@ int main(int argc, char *argv[])
if (n <= 0) { perror("ID"); }
}
else if (strcmp(buf, "AI;") == 0)
{
printf("%s\n", buf);
usleep(50 * 1000);
SNPRINTF(buf, sizeof(buf), "AI0;");
n = write(fd, buf, strlen(buf));
printf("n=%d\n", n);
if (n <= 0) { perror("ID"); }
}
#if 0
else if (strncmp(buf, "AI", 2) == 0)
{
if (strcmp(buf, "AI;"))
{
printf("%s\n", buf);
usleep(50 * 1000);
n = fprintf(fp, "%s", "AI0;");
printf("n=%d\n", n);
if (n <= 0) { perror("AI"); }
}
}
#endif
else if (strcmp(buf, "VS;") == 0)
{
printf("%s\n", buf);
usleep(50 * 1000);
pbuf = "VS0;";
n = write(fd, pbuf, strlen(pbuf));
printf("n=%d\n", n);
if (n < 0) { perror("VS"); }
}
else if (strcmp(buf, "EX032;") == 0)
{
static int ant = 0;

Wyświetl plik

@ -159,42 +159,6 @@ int main(int argc, char *argv[])
if (n <= 0) { perror("ID"); }
}
else if (strcmp(buf, "AI;") == 0)
{
printf("%s\n", buf);
usleep(50 * 1000);
SNPRINTF(buf, sizeof(buf), "AI0;");
n = write(fd, buf, strlen(buf));
printf("n=%d\n", n);
if (n <= 0) { perror("ID"); }
}
#if 0
else if (strncmp(buf, "AI", 2) == 0)
{
if (strcmp(buf, "AI;"))
{
printf("%s\n", buf);
usleep(50 * 1000);
n = fprintf(fp, "%s", "AI0;");
printf("n=%d\n", n);
if (n <= 0) { perror("AI"); }
}
}
#endif
else if (strcmp(buf, "VS;") == 0)
{
printf("%s\n", buf);
usleep(50 * 1000);
pbuf = "VS0;";
n = write(fd, pbuf, strlen(pbuf));
printf("n=%d\n", n);
if (n < 0) { perror("VS"); }
}
else if (strcmp(buf, "EX032;") == 0)
{
static int ant = 0;