Skip to content

Commit 747dc66

Browse files
committed
Merge pull request #7 from djs55/ipv4-monitor
Report IPv4 addresses as well as IPV6 addresses.
2 parents 41714b7 + 08723e5 commit 747dc66

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

networkd/network_monitor_thread.ml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -249,15 +249,14 @@ let signal_networking_change () =
249249

250250
let ip_watcher () =
251251
let cmd = Network_utils.iproute2 in
252-
(* Only monitor IPv6 addresses at the moment *)
253-
let args = ["-6"; "monitor"; "address"] in
252+
let args = ["monitor"; "address"] in
254253
let readme, writeme = Unix.pipe () in
255254
Mutex.execute watcher_m (fun () ->
256255
watcher_pid := Some (Forkhelpers.safe_close_and_exec ~env:(Unix.environment ()) None (Some writeme) None [] cmd args)
257256
);
258257
Unix.close writeme;
259258
let in_channel = Unix.in_channel_of_descr readme in
260-
debug "Started IPv6 watcher thread";
259+
debug "Started IP watcher thread";
261260
let rec loop () =
262261
let line = input_line in_channel in
263262
(* Do not send events for link-local IPv6 addresses *)

0 commit comments

Comments
 (0)