Fix various typos in docs/comments
authorluz paz <luzpaz@users.noreply.github.com>
Sat, 30 Oct 2021 21:15:04 +0000 (17:15 -0400)
committerTormod Volden <debian.tormod@gmail.com>
Sun, 31 Oct 2021 16:44:55 +0000 (17:44 +0100)
Found via `codespell -q 3`

Closes #1015

ChangeLog
android/README
examples/ezusb.c
examples/xusb.c
libusb/io.c
libusb/os/darwin_usb.c
libusb/os/haiku_usb_backend.cpp
tests/stress.c

index 3fe00a1..b4a09fa 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -66,7 +66,7 @@ visit: http://log.libusb.info
 * Windows: Fix enumeration problems on Windows 8 and later
 * Windows: Major rework of poll() emulation
 * Windows: Numerous HID API fixes
-* Windows: Support cancelation of individual transfers (Vista and later)
+* Windows: Support cancellation of individual transfers (Vista and later)
 * Various other bug fixes and improvements
 
 2016-10-01: v1.0.21
index 9534036..4af4c3d 100644 (file)
@@ -51,7 +51,7 @@ the package is built.
 Runtime Permissions:
 --------------------
 
-The Runtime Permissions on Android can be transfered from Java to Native
+The Runtime Permissions on Android can be transferred from Java to Native
 over the following approach:
 
   JAVA:
@@ -85,7 +85,7 @@ over the following approach:
           libusb_init(&ctx);
           libusb_wrap_sys_device(NULL, (intptr_t)fileDescriptor, &devh);
       }
-      /* From this point you can regulary use all libusb functions as usual */
+      /* From this point you can regularly use all libusb functions as usual */
 
    About LIBUSB_OPTION_NO_DEVICE_DISCOVERY:
 
index 6abd47d..ec60b0e 100644 (file)
@@ -195,7 +195,7 @@ static bool ezusb_cpucs(libusb_device_handle *device, uint32_t addr, bool doRun)
 }
 
 /*
- * Send an FX3 jumpt to address command
+ * Send an FX3 jump to address command
  * Returns false on error.
  */
 static bool ezusb_fx3_jump(libusb_device_handle *device, uint32_t addr)
index cf7c7a8..45d2e35 100644 (file)
@@ -220,7 +220,7 @@ static int display_ps3_status(libusb_device_handle *handle)
                        printf("\tRIGHT 3 pressed\n");
                        break;
                case 0x08:
-                       printf("\tSTART presed\n");
+                       printf("\tSTART pressed\n");
                        break;
                case 0x10:
                        printf("\tUP pressed\n");
@@ -246,7 +246,7 @@ static int display_ps3_status(libusb_device_handle *handle)
                        printf("\tLEFT 1 pressed\n");
                        break;
                case 0x08:
-                       printf("\tRIGHT 1 presed\n");
+                       printf("\tRIGHT 1 pressed\n");
                        break;
                case 0x10:
                        printf("\tTRIANGLE pressed\n");
index 90f6464..0d2ac9e 100644 (file)
@@ -1544,7 +1544,7 @@ int API_EXPORTED libusb_submit_transfer(struct libusb_transfer *transfer)
        }
        /*
         * We must release the flying transfers lock here, because with
-        * some backends the submit_transfer method is synchroneous.
+        * some backends the submit_transfer method is synchronous.
         */
        usbi_mutex_unlock(&ctx->flying_transfers_lock);
 
index a2da0cf..10af647 100644 (file)
@@ -1620,7 +1620,7 @@ static int darwin_set_interface_altsetting(struct libusb_device_handle *dev_hand
 
   /* If a device only supports a default setting for the specified interface, then a STALL
      (kIOUSBPipeStalled) may be returned. Ref: USB 2.0 specs 9.4.10.
-     Mimick the behaviour in e.g. the Linux kernel: in such case, reset all endpoints
+     Mimic the behaviour in e.g. the Linux kernel: in such case, reset all endpoints
      of the interface (as would have been done per 9.1.1.5) and return success. */
 
   /* For some reason we need to reclaim the interface after the pipe error */
index e1d7efe..2fcefdd 100644 (file)
@@ -301,7 +301,7 @@ USBDeviceHandle::SetAltSetting(uint8 inumber, uint8 alt)
        }
        command.alternate.alternate_info = alt;
        if (ioctl(fRawFD, B_USB_RAW_COMMAND_SET_ALT_INTERFACE, &command, sizeof(command)) ||
-                       command.alternate.status != B_USB_RAW_STATUS_SUCCESS) { //IF IOCTL FAILS DEVICE DISONNECTED PROBABLY
+                       command.alternate.status != B_USB_RAW_STATUS_SUCCESS) { //IF IOCTL FAILS DEVICE DISCONNECTED PROBABLY
                usbi_err(NULL, "Error setting alternate interface");
                return _errno_to_libusb(command.alternate.status);
        }
index a5c9d50..0dc9173 100644 (file)
@@ -133,7 +133,7 @@ static libusb_testlib_result test_default_context_change(void)
                /* Enable debug output on new context, to be sure to use the context */
                libusb_set_option(ctx, LIBUSB_OPTION_LOG_LEVEL, LIBUSB_LOG_LEVEL_DEBUG);
 
-               /* Enable debug outout on the default context. This should work even before
+               /* Enable debug output on the default context. This should work even before
                 * the context has been created. */
                libusb_set_option(NULL, LIBUSB_OPTION_LOG_LEVEL, LIBUSB_LOG_LEVEL_DEBUG);