Fix warnings

This commit is contained in:
Adam Honse 2025-02-10 10:21:36 -06:00
parent 02af851705
commit 14d3c68145
3 changed files with 3 additions and 5 deletions

View file

@ -852,8 +852,6 @@ void KeyboardLayoutManager::AddAltName(keyboard_led key)
\*---------------------------------------------------------------------*/
unsigned int edit_row = key.row;
unsigned int edit_col = key.col;
const char* edit_name = key.name;
unsigned int edit_value = key.value;
const char* edit_alt_name = key.alt_name;
/*---------------------------------------------------------------------*\

View file

@ -282,7 +282,7 @@ unsigned char * RGBController::GetDeviceDescription(unsigned int protocol_versio
/*-----------------------------------------------------*\
| LED alternate name strings |
\*-----------------------------------------------------*/
for(int led_idx = 0; led_idx < led_alt_names.size(); led_idx++)
for(std::size_t led_idx = 0; led_idx < led_alt_names.size(); led_idx++)
{
data_size += sizeof(unsigned short);
data_size += strlen(led_alt_names[led_idx].c_str()) + 1;
@ -725,7 +725,7 @@ unsigned char * RGBController::GetDeviceDescription(unsigned int protocol_versio
memcpy(&data_buf[data_ptr], &num_led_alt_names, sizeof(num_led_alt_names));
data_ptr += sizeof(num_led_alt_names);
for(int led_idx = 0; led_idx < led_alt_names.size(); led_idx++)
for(std::size_t led_idx = 0; led_idx < led_alt_names.size(); led_idx++)
{
/*---------------------------------------------------------*\
| Copy in LED alternate name (size+data) |

View file

@ -1033,7 +1033,7 @@ bool DeviceView::selectZone(int zone, bool add)
int zoneStart = controller->zones[zone].start_idx;
for(int led_idx = 0; led_idx < controller->GetLEDsInZone(zone); led_idx++)
for(std::size_t led_idx = 0; led_idx < controller->GetLEDsInZone(zone); led_idx++)
{
if(!selectionFlags[zoneStart + led_idx])
{