Development discussion of WireGuard
 help / color / mirror / Atom feed
From: Loren McIntyre <loren@mcint.io>
To: wireguard@lists.zx2c4.com
Cc: Loren McIntyre <loren@mcint.io>
Subject: [PATCH 1/2] wg-quick: darwin: restore original dns settings on failed up
Date: Thu, 21 Jan 2021 22:58:57 -0800	[thread overview]
Message-ID: <20210122065858.41605-1-loren@mcint.io> (raw)
In-Reply-To: <7a51e0ee-73f8-441a-9cdd-3aa305832c85@www.fastmail.com>

---
 src/wg-quick/darwin.bash | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/wg-quick/darwin.bash b/src/wg-quick/darwin.bash
index cde1b54..9c92f87 100755
--- a/src/wg-quick/darwin.bash
+++ b/src/wg-quick/darwin.bash
@@ -449,7 +449,7 @@ cmd_usage() {
 cmd_up() {
 	local i
 	get_real_interface && die "\`$INTERFACE' already exists as \`$REAL_INTERFACE'"
-	trap 'del_if; del_routes; exit' INT TERM EXIT
+	trap 'del_if; del_routes; del_dns; exit' INT TERM EXIT
 	execute_hooks "${PRE_UP[@]}"
 	add_if
 	set_config
-- 
2.29.2


  reply	other threads:[~2021-01-24 16:30 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-01-22  6:57 wg-quick: darwin: DNS cleanup & disabled/inactive interface causing setup to fail Loren McIntyre
2021-01-22  6:58 ` Loren McIntyre [this message]
2021-01-22  6:58   ` [PATCH 2/2] wg-quick: darwin: handle disabled interface Loren McIntyre

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20210122065858.41605-1-loren@mcint.io \
    --to=loren@mcint.io \
    --cc=wireguard@lists.zx2c4.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).