diff options
author | Ori Bernstein <ori@eigenstate.org> | 2023-05-14 23:56:11 +0000 |
---|---|---|
committer | Ori Bernstein <ori@eigenstate.org> | 2023-05-14 23:56:11 +0000 |
commit | dfca0be219074f8473683256b1b9ca986ec37c43 (patch) | |
tree | 95840ebea0534036815ab527c1f5df00d271b2ca | |
parent | 3e44af25c66c8e04f22476a23556e5f848627185 (diff) |
dhcp: skip android junk options
-rw-r--r-- | sys/src/cmd/ip/ipconfig/dhcp.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/sys/src/cmd/ip/ipconfig/dhcp.c b/sys/src/cmd/ip/ipconfig/dhcp.c index 6d710a51e..dc26c401c 100644 --- a/sys/src/cmd/ip/ipconfig/dhcp.c +++ b/sys/src/cmd/ip/ipconfig/dhcp.c @@ -950,6 +950,11 @@ parseoptions(uchar *p, int n) int code, len, nin = n; while (n > 0) { + /* Android shouldn't be sending us this garbage; filter it out */ + if(strncmp((char*)p, "ANDROID_METERED", n) == 0){ + p += strlen("ANDROID_METERED"); + continue; + } code = *p++; n--; if(code == OBend) |