From f3b84aff36a896635953a771ac1ab7da085a8f52 Mon Sep 17 00:00:00 2001 From: Clinton Ebadi Date: Fri, 28 Mar 2014 21:32:45 -0400 Subject: [PATCH] Quiet compiler warning for Firewall.format{Input,Output}Rules I think the type needs rethinking to make the case exhaustive --- src/plugins/firewall.sml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/plugins/firewall.sml b/src/plugins/firewall.sml index d58c251..daa4b11 100644 --- a/src/plugins/firewall.sml +++ b/src/plugins/firewall.sml @@ -85,10 +85,12 @@ fun formatHosts hosts = "(" ^ String.concatWith " " hosts ^ ")" fun formatOutputRule (Client (ports, hosts)) = "dport " ^ formatPorts ports ^ (case hosts of [] => "" | _ => " daddr " ^ formatHosts hosts) ^ " ACCEPT;" + | formatOutputRule _ = "" fun formatInputRule (Server (ports, hosts)) = "dport " ^ formatPorts ports ^ (case hosts of [] => "" | _ => " saddr " ^ formatHosts hosts) ^ " ACCEPT;" + | formatInputRule _ = "" type ferm_lines = { input_rules : (string list) DataStructures.StringMap.map, output_rules : (string list) DataStructures.StringMap.map } -- 2.20.1