--- freem/src/cmd_unmap.c 2025/03/09 19:14:24 1.3 +++ freem/src/cmd_unmap.c 2025/04/09 19:52:02 1.4 @@ -1,5 +1,5 @@ /* - * $Id: cmd_unmap.c,v 1.3 2025/03/09 19:14:24 snw Exp $ + * $Id: cmd_unmap.c,v 1.4 2025/04/09 19:52:02 snw Exp $ * Implementation of the UNMAP command * * @@ -24,6 +24,9 @@ * along with FreeM. If not, see . * * $Log: cmd_unmap.c,v $ + * Revision 1.4 2025/04/09 19:52:02 snw + * Eliminate as many warnings as possible while building with -Wall + * * Revision 1.3 2025/03/09 19:14:24 snw * First phase of REUSE compliance and header reformat * @@ -39,7 +42,6 @@ MRESULT cmd_unmap(MACTION *ra) { - char mapping_type; char mapping_obj[256]; char tmp_data[256]; char tmp_key[256]; @@ -54,15 +56,8 @@ MRESULT cmd_unmap(MACTION *ra) expr (NAME); if (merr ()) return merr (); - - if (stcmp (varnam, "GLOBAL\201") == 0 || stcmp (varnam, "global\201") == 0) { - mapping_type = 'g'; - } - else if (stcmp (varnam, "ROUTINE\201") == 0 || stcmp (varnam, "routine\201") == 0) { - mapping_type = 'r'; - return ARGLIST; - } - else { + + if (stcmp (varnam, "GLOBAL\201") != 0 && stcmp (varnam, "global\201") != 0 && stcmp (varnam, "ROUTINE\201") != 0 && stcmp (varnam, "routine\201") != 0) { return ARGLIST; }