diff --git a/desmume/src/frontend/posix/gtk/main.cpp b/desmume/src/frontend/posix/gtk/main.cpp index 8bbb159ad..172d2b2d2 100644 --- a/desmume/src/frontend/posix/gtk/main.cpp +++ b/desmume/src/frontend/posix/gtk/main.cpp @@ -1961,7 +1961,7 @@ static void Edit_Joystick_Controls(GSimpleAction *action, GVariant *parameter, g switch (gtk_dialog_run(GTK_DIALOG(ecDialog))) { case GTK_RESPONSE_OK: - memcpy(&joypad_cfg, &Keypad_Temp, sizeof(keyboard_cfg)); + memcpy(&joypad_cfg, &Keypad_Temp, sizeof(joypad_cfg)); desmume_config_update_joykeys(keyfile); break; case GTK_RESPONSE_CANCEL: diff --git a/desmume/src/frontend/posix/gtk2/main.cpp b/desmume/src/frontend/posix/gtk2/main.cpp index 2d60bd13d..55610d528 100644 --- a/desmume/src/frontend/posix/gtk2/main.cpp +++ b/desmume/src/frontend/posix/gtk2/main.cpp @@ -2365,7 +2365,7 @@ static void Edit_Joystick_Controls() switch (gtk_dialog_run(GTK_DIALOG(ecDialog))) { case GTK_RESPONSE_OK: - memcpy(&joypad_cfg, &Keypad_Temp, sizeof(keyboard_cfg)); + memcpy(&joypad_cfg, &Keypad_Temp, sizeof(joypad_cfg)); desmume_config_update_joykeys(keyfile); break; case GTK_RESPONSE_CANCEL: