about summary refs log tree commit diff stats
path: root/src/local/client.nim
diff options
context:
space:
mode:
authorbptato <nincsnevem662@gmail.com>2024-01-29 13:25:23 +0100
committerbptato <nincsnevem662@gmail.com>2024-01-29 13:26:15 +0100
commit9318ad33229d3c2f96dd766b38b8748f77487c5a (patch)
tree34dc6cbfd0a52d521d9d125fea626895ec3548c8 /src/local/client.nim
parent619d5296dbfc77c37c13b86e4e96c356f1c3f61a (diff)
downloadchawan-9318ad33229d3c2f96dd766b38b8748f77487c5a.tar.gz
forkserver: clean up
Move forkBuffer into forkserver (why was it in container anyway), remove
unused mainproc variable, etc.
Diffstat (limited to 'src/local/client.nim')
-rw-r--r--src/local/client.nim6
1 files changed, 2 insertions, 4 deletions
diff --git a/src/local/client.nim b/src/local/client.nim
index efc838f4..ae838360 100644
--- a/src/local/client.nim
+++ b/src/local/client.nim
@@ -65,7 +65,6 @@ type
     jsctx: JSContext
     jsrt: JSRuntime
     loader: FileLoader
-    mainproc: Pid
     pager {.jsget.}: Pager
     selector: Selector[int]
     timeouts: TimeoutState
@@ -676,17 +675,16 @@ proc addJSModules(client: Client, ctx: JSContext) =
 func getClient(client: Client): Client {.jsfget: "client".} =
   return client
 
-proc newClient*(config: Config, forkserver: ForkServer, mainproc: Pid): Client =
+proc newClient*(config: Config, forkserver: ForkServer): Client =
   setControlCHook(proc() {.noconv.} = quit(1))
   let jsrt = newJSRuntime()
   JS_SetModuleLoaderFunc(jsrt, normalizeModuleName, clientLoadJSModule, nil)
   let jsctx = jsrt.newJSContext()
   let attrs = getWindowAttributes(stdout)
-  let pager = newPager(config, attrs, forkserver, mainproc, jsctx)
+  let pager = newPager(config, attrs, forkserver, jsctx)
   let client = Client(
     config: config,
     forkserver: forkserver,
-    mainproc: mainproc,
     loader: forkserver.newFileLoader(
       defaultHeaders = config.getDefaultHeaders(),
       proxy = config.getProxy(),