aboutsummaryrefslogtreecommitdiffstats
path: root/executor
diff options
context:
space:
mode:
Diffstat (limited to 'executor')
-rw-r--r--executor/common_usb.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/executor/common_usb.h b/executor/common_usb.h
index e342d8085..39c855331 100644
--- a/executor/common_usb.h
+++ b/executor/common_usb.h
@@ -199,7 +199,7 @@ static bool lookup_connect_response(struct vusb_connect_descriptors* descs, stru
return true;
case USB_DT_STRING:
str_idx = (uint8)ctrl->wValue;
- if (str_idx >= descs->strs_len) {
+ if (!descs || str_idx >= descs->strs_len) {
// Use the default string if we ran out.
*response_data = (char*)default_string;
*response_length = strlen(default_string);