The open source OpenXR runtime
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

st/prober: Fix warning and tidy code

+1 -5
+1 -5
src/xrt/state_trackers/prober/p_udev.c
··· 583 583 ok = true; 584 584 } 585 585 } else if (strncmp(line, "HID_NAME=", 9) == 0) { 586 - product_name[0] = '\0'; 587 - strncat(product_name, line + 9, sizeof(product_name)); 588 - 589 - // U_LOG_D("\t\tprocuct_name: '%s'", *out_product_name); 586 + snprintf(product_name, sizeof(product_name), "%s", line + 9); 590 587 } else if (strncmp(line, "HID_UNIQ=", 9) == 0) { 591 588 serial_utf8 = &line[9]; 592 - // U_LOG_D("\t\tserial: '%s'", line + 9); 593 589 } 594 590 595 591 line = strtok_r(NULL, "\n", &saveptr);