Mercurial > hg > dmlib
changeset 2492:1bd7387984ed
Add few comments to the -R sub-option parsing and remove dead code.
author | Matti Hamalainen <ccr@tnsp.org> |
---|---|
date | Tue, 28 Apr 2020 19:26:04 +0300 |
parents | ed2f56abda22 |
children | ec036e88a0c2 |
files | tools/gfxconv.c |
diffstat | 1 files changed, 6 insertions(+), 8 deletions(-) [+] |
line wrap: on
line diff
--- a/tools/gfxconv.c Tue Apr 28 19:16:19 2020 +0300 +++ b/tools/gfxconv.c Tue Apr 28 19:26:04 2020 +0300 @@ -990,14 +990,16 @@ break; case 42: + // Check if any flags/sub-options are specified if ((tmpStr = strchr(optArg, '+')) != NULL) { *tmpStr++ = 0; do { - char sep, *topt; - topt = dmParseValWithSep(&tmpStr, &sep, NULL, "+"); - + // Parse one sub-option + char sep, *topt = dmParseValWithSep(&tmpStr, &sep, NULL, "+"); + + // Check what option we have if (strcasecmp(topt, "remove") == 0) optRemapRemove = TRUE; else @@ -1044,6 +1046,7 @@ } while (*tmpStr != 0); } + // Check which remap mode is being requested if (strcasecmp(optArg, "auto") == 0) { if (optRemapMode != REMAP_NONE && optRemapMode != REMAP_AUTO) @@ -1052,11 +1055,6 @@ return FALSE; } - // Check if we have more? - if (optArg[4] == ':') - { - } - optRemapMode = REMAP_AUTO; } else