Fixed gfx-h264 option parsing.
authorakallabeth <akallabeth@posteo.net>
Sun, 15 Mar 2020 09:33:34 +0000 (10:33 +0100)
committerakallabeth <akallabeth@posteo.net>
Sun, 15 Mar 2020 09:33:34 +0000 (10:33 +0100)
client/common/cmdline.c

index e732e21..f646e93 100644 (file)
@@ -2547,10 +2547,14 @@ int freerdp_client_settings_parse_command_line_arguments(rdpSettings* settings,
 
                                                if (_strnicmp("AVC444", val, 7) == 0)
                                                {
+                                                       settings->GfxH264 = TRUE;
                                                        settings->GfxAVC444 = TRUE;
                                                }
-                                               else if (_strnicmp("AVC420", val, 7) != 0)
-                                                       rc = COMMAND_LINE_ERROR;
+                                               else if (_strnicmp("AVC420", val, 7) == 0)
+                                               {
+                                                       settings->GfxH264 = TRUE;
+                                                       settings->GfxAVC444 = FALSE;
+                                               }
                                                else if (_strnicmp("mask:", val, 5) == 0)
                                                {
                                                        ULONGLONG v;
@@ -2560,6 +2564,8 @@ int freerdp_client_settings_parse_command_line_arguments(rdpSettings* settings,
                                                        else
                                                                settings->GfxCapsFilter = (UINT32)v;
                                                }
+                                               else
+                                                       rc = COMMAND_LINE_ERROR;
                                        }
                                }
                                free(p);