about summary refs log tree commit diff stats
path: root/src/config
diff options
context:
space:
mode:
authorbptato <nincsnevem662@gmail.com>2024-05-16 18:35:22 +0200
committerbptato <nincsnevem662@gmail.com>2024-05-16 18:58:13 +0200
commited84d7223fd8945705dcedd204fee137b249c524 (patch)
tree3539b9ccb5af2de6ad66e6d3362bff83abc1df88 /src/config
parent87a5c636eb203cd066a620129f93c30b02245ad9 (diff)
downloadchawan-ed84d7223fd8945705dcedd204fee137b249c524.tar.gz
config: separate tmp dir for sockets, users
* add $LOGNAME to the tmp directory name, so that tmpdirs of separate
  users don't conflict
* use separate directory for sockets, so that we do not have to give
  buffers access to all cached pages
Diffstat (limited to 'src/config')
-rw-r--r--src/config/config.nim11
1 files changed, 1 insertions, 10 deletions
diff --git a/src/config/config.nim b/src/config/config.nim
index 872f0440..4869d79c 100644
--- a/src/config/config.nim
+++ b/src/config/config.nim
@@ -86,6 +86,7 @@ type
 
   ExternalConfig = object
     tmpdir* {.jsgetset.}: ChaPathResolved
+    sockdir* {.jsgetset.}: ChaPathResolved
     editor* {.jsgetset.}: string
     mailcap*: Mailcap
     mime_types*: MimeTypes
@@ -149,10 +150,6 @@ type
     page* {.jsget.}: ActionMap
     line* {.jsget.}: ActionMap
 
-  ForkServerConfig* = object
-    tmpdir*: string
-    ambiguous_double*: bool
-
 jsDestructor(ActionMap)
 jsDestructor(StartConfig)
 jsDestructor(CSSConfig)
@@ -284,12 +281,6 @@ proc readUserStylesheet(dir, file: string): string =
     result = s.readAll()
     s.close()
 
-proc getForkServerConfig*(config: Config): ForkServerConfig =
-  return ForkServerConfig(
-    tmpdir: config.external.tmpdir,
-    ambiguous_double: config.display.double_width_ambiguous
-  )
-
 type ConfigParser = object
   config: Config
   dir: string