summaryrefslogtreecommitdiff
path: root/main.go
diff options
context:
space:
mode:
authorRyan Dahl <ry@tinyclouds.org>2018-05-14 17:27:34 -0400
committerRyan Dahl <ry@tinyclouds.org>2018-05-14 17:28:31 -0400
commit362aa677b404408a341dc0ddd2e1801c9d0fc200 (patch)
treee74408d405285ca9e948acba82e09452e5b2e2f1 /main.go
parent50105d7855f69190f235ebd50e261863905ef173 (diff)
Support relative import.
Diffstat (limited to 'main.go')
-rw-r--r--main.go4
1 files changed, 4 insertions, 0 deletions
diff --git a/main.go b/main.go
index e634a6abe..6e38d5f95 100644
--- a/main.go
+++ b/main.go
@@ -31,9 +31,13 @@ func recv(buf []byte) []byte {
switch msg.Kind {
case Msg_READ_FILE_SYNC:
return ReadFileSync(msg.Path)
+ case Msg_EXIT:
+ os.Exit(int(msg.Code))
default:
panic("Unexpected message")
}
+
+ return nil
}
func loadAsset(w *v8worker2.Worker, path string) {