ipc, rwcancel: compile on js/wasm

Signed-off-by: Brad Fitzpatrick <bradfitz@tailscale.com>
This commit is contained in:
Brad Fitzpatrick 2021-10-20 08:56:39 -07:00 committed by Jason A. Donenfeld
parent fdf57a1fa4
commit 82e0b734e5
3 changed files with 18 additions and 1 deletions

15
ipc/uapi_js.go Normal file
View file

@ -0,0 +1,15 @@
/* SPDX-License-Identifier: MIT
*
* Copyright (C) 2021 WireGuard LLC. All Rights Reserved.
*/
package ipc
// Made up sentinel error codes for the js/wasm platform.
const (
IpcErrorIO = 1
IpcErrorInvalid = 2
IpcErrorPortInUse = 3
IpcErrorUnknown = 4
IpcErrorProtocol = 5
)

View file

@ -1,4 +1,4 @@
//go:build !windows
//go:build !windows && !js
/* SPDX-License-Identifier: MIT
*

View file

@ -1,3 +1,5 @@
//go:build windows || js
// SPDX-License-Identifier: MIT
package rwcancel