]> datadissipation.net git - ust.git/commitdiff
remove typos
authorgit <redacted>
Sun, 15 Mar 2026 12:30:50 +0000 (08:30 -0400)
committergit <redacted>
Sun, 15 Mar 2026 12:30:50 +0000 (08:30 -0400)
ust.c

diff --git a/ust.c b/ust.c
index 9cb40535a7dabbd201a268b34cfb9b5ca2c1632c..392bc439a08122db374a5c29bb61919516adfec9 100644 (file)
--- a/ust.c
+++ b/ust.c
@@ -129,11 +129,11 @@ settermspd(unsigned int lispeed, unsigned int lospeed, struct TERMIOS_STRUCT *op
        #ifdef __linux__
         optst->c_cflag &= ~CBAUD;
         optst->c_cflag |= BOTHER;
-        optst->c_ispeed = ispeed;
-        optst->c_ospeed = ospeed;
+        optst->c_ispeed = lispeed;
+        optst->c_ospeed = lospeed;
        #else
-        cfsetispeed(optst, ispeed);
-        cfsetospeed(optst, ospeed);
+        cfsetispeed(optst, lispeed);
+        cfsetospeed(optst, lospeed);
        #endif
 }
 
@@ -877,7 +877,7 @@ main(int argc, char *argv[])
                        soft ^= 1; break;
                case 'd':
                        tl = strtol(optarg, &endptr, 10);
-                       if (errno != 0 || *endptr != '\0' || t < 0) {
+                       if (errno != 0 || *endptr != '\0' || tl < 0) {
                                fprintf(stderr, "%s: invalid character delay: %s\n", argv[0],optarg);
                                goto ustusage;
                        } else {