Skip to content

Commit

Permalink
Added TS IP to Menu
Browse files Browse the repository at this point in the history
  • Loading branch information
sithtoast committed Sep 12, 2023
1 parent 4d416ba commit 72440f7
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions menu.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -604,7 +604,7 @@ static char* getNet(int spec)

if ((strcmp(ifa->ifa_name, "eth0") == 0) && (ifa->ifa_addr->sa_family == AF_INET)) ifae = ifa;
if ((strncmp(ifa->ifa_name, "wlan", 4) == 0) && (ifa->ifa_addr->sa_family == AF_INET)) ifaw = ifa;
if ((strcmp(ifa->ifa_name, "tailscale", 4) == 0) && (ifa->ifa_addr->sa_family == AF_INET)) ifat = ifa;
if ((strcmp(ifa->ifa_name, "tailscale0") == 0) && (ifa->ifa_addr->sa_family == AF_INET)) ifat = ifa;
}

ifa = 0;
Expand All @@ -624,8 +624,8 @@ static char* getNet(int spec)
if (ifat && (!spec || spec == 3))
{
ifa = ifat;
nettype = 3;

netType = 3;
}
if (spec && ifa)
{
strcpy(host, "IP: ");
Expand Down Expand Up @@ -682,7 +682,7 @@ static void printSysInfo()
net = getNet(3);
if (net)
{
sprintf(str, "TS:", net);
sprintf(str, "\x1c %s", net);
infowrite(n++, str);
j++;
}
Expand Down

0 comments on commit 72440f7

Please sign in to comment.