From bc3551ff3626d36bffc3458dbb885990a4ea0bc5 Mon Sep 17 00:00:00 2001 From: Vincent Hanquez Date: Wed, 22 Jul 2009 11:27:20 +0100 Subject: [PATCH] add dbus notification option dummy --- xenvm/vmact.ml | 2 ++ xenvm/vmconfig.ml | 8 ++++++++ 2 files changed, 10 insertions(+) diff --git a/xenvm/vmact.ml b/xenvm/vmact.ml index 38d1408..56562ec 100644 --- a/xenvm/vmact.ml +++ b/xenvm/vmact.ml @@ -47,6 +47,8 @@ let _notify state code l = Some fd | NotifyTcp6 _ -> None + | NotifyDBus path -> + None | NotifyNone -> None in diff --git a/xenvm/vmconfig.ml b/xenvm/vmconfig.ml index e732cb3..2493419 100644 --- a/xenvm/vmconfig.ml +++ b/xenvm/vmconfig.ml @@ -24,6 +24,7 @@ type notify_ty = | NotifyTcp6 of string | NotifyTcp of Unix.inet_addr * int | NotifyUnix of string + | NotifyDBus of string option | NotifyNone let string_of_notify ty = @@ -31,6 +32,7 @@ let string_of_notify ty = | NotifyTcp6 s -> sprintf "tcp6,%s" s | NotifyTcp (iaddr, port) -> sprintf "tcp,%s:%d" "" port | NotifyUnix path -> sprintf "unix,%s" path + | NotifyDBus path -> sprintf "dbus%s" (match path with None -> "" | Some path -> "," ^ path) | NotifyNone -> "" type snapshot_mode = @@ -272,6 +274,12 @@ let config_notify_of_string s = failwith "notify: tcp6 not implemented" | "unix" :: path :: [] -> NotifyUnix path + | "dbus" :: args -> ( + match args with + | [] -> NotifyDBus (None) + | path :: [] -> NotifyDBus (Some path) + | _ -> failwith "notify: bad dbus format" + ) | _ -> failwith "bah" -- 2.39.5