Skip to content

Commit 71a866b

Browse files
committed
測試
1 parent 06abe3c commit 71a866b

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

QuickIPchange/Form1.vb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -135,7 +135,7 @@ Public Class Form1
135135

136136
End Sub
137137

138-
#Region "檢查更新&檢什UAC權限"
138+
#Region "檢查更新&檢查UAC權限"
139139
Private Async Function getGithubReleases() As Task(Of Dictionary(Of String, String))
140140
Dim result As New Dictionary(Of String, String)
141141
Dim apiUrl As String = "https://api.github.com/repos/InterfaceGUI/QuickIPchange/releases/latest"
@@ -273,7 +273,7 @@ Public Class Form1
273273
Try
274274
Dim processStartInfo As New ProcessStartInfo()
275275
processStartInfo.FileName = "netsh"
276-
processStartInfo.Arguments = $"interface ip set address ""{adapterName}"" static {ip} {subnet} {gateway}"
276+
processStartInfo.Arguments = $"interface ip set address ""{adapterName}"" static {ip} {subnet} {IIf(gateway = "", "0.0.0.0", gateway)}"
277277
processStartInfo.RedirectStandardOutput = True
278278
processStartInfo.UseShellExecute = False
279279
processStartInfo.CreateNoWindow = True

0 commit comments

Comments
 (0)