lint: fix
This commit is contained in:
parent
5bdc10e84d
commit
d26d71af5f
@ -125,7 +125,7 @@ export default class SsBasePreset extends IPresetAddressing {
|
||||
port = buffer.slice(17, 19).readUInt16BE(0);
|
||||
offset += 16;
|
||||
break;
|
||||
case ATYP_DOMAIN:
|
||||
case ATYP_DOMAIN: {
|
||||
const domainLen = buffer[1];
|
||||
if (buffer.length < domainLen + 4) {
|
||||
return fail(`invalid length: ${buffer.length}`);
|
||||
@ -137,6 +137,7 @@ export default class SsBasePreset extends IPresetAddressing {
|
||||
port = buffer.slice(2 + domainLen, 4 + domainLen).readUInt16BE(0);
|
||||
offset += (domainLen + 1);
|
||||
break;
|
||||
}
|
||||
default:
|
||||
return fail(`invalid atyp: ${atyp}`);
|
||||
}
|
||||
|
@ -21,7 +21,7 @@ export default async function curl(args) {
|
||||
case 'https':
|
||||
command.push(`--proxy-insecure -x https://${proxyHost}:${proxyPort}`);
|
||||
break;
|
||||
default:
|
||||
default: {
|
||||
const proxy = {
|
||||
'socks': '--socks5',
|
||||
'socks4': '--socks4',
|
||||
@ -32,6 +32,7 @@ export default async function curl(args) {
|
||||
command.push(`${proxy} ${proxyHost}:${proxyPort}`);
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
command.push(`${targetHost}:${targetPort}`);
|
||||
command = command.join(' ');
|
||||
|
Loading…
Reference in New Issue
Block a user