The Lambda Lab
/
projects
/
scratchy.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
074b068
)
Another bugfix.
author
Tim Vaughan
<tgvaughan@gmail.com>
Sat, 4 May 2019 10:06:24 +0000
(12:06 +0200)
committer
Tim Vaughan
<tgvaughan@gmail.com>
Sat, 4 May 2019 10:06:24 +0000
(12:06 +0200)
burrow.scm
patch
|
blob
|
history
diff --git
a/burrow.scm
b/burrow.scm
index
6be3251
..
60f9b98
100644
(file)
--- a/
burrow.scm
+++ b/
burrow.scm
@@
-87,12
+87,12
@@
(selector (car selector-list))
(arguments (cdr selector-list)))
(case (infer-selector-type selector)
(selector (car selector-list))
(arguments (cdr selector-list)))
(case (infer-selector-type selector)
- ((1) (serve-directory selector
remote-ip
config))
+ ((1) (serve-directory selector config))
((0) (serve-text-file selector config))
((7) (serve-query selector arguments remote-ip config))
(else (serve-binary-file selector config)))))
((0) (serve-text-file selector config))
((7) (serve-query selector arguments remote-ip config))
(else (serve-binary-file selector config)))))
-(define (serve-directory selector
remote-ip
config)
+(define (serve-directory selector config)
(let ((file-name (make-pathname (list (config-root-dir config) selector)
gopher-index-file-name)))
(if (regular-file? file-name)
(let ((file-name (make-pathname (list (config-root-dir config) selector)
gopher-index-file-name)))
(if (regular-file? file-name)
@@
-106,7
+106,7
@@
(if (eq? c #\,)
(begin
(read-char)
(if (eq? c #\,)
(begin
(read-char)
- (serve-record (read) selector
remote-ip
config)
+ (serve-record (read) selector config)
(read-line))
(serve-info-records (read-line)))
(loop (peek-char)))))))
(read-line))
(serve-info-records (read-line)))
(loop (peek-char)))))))
@@
-256,9
+256,9
@@
(config-port-set! config (string->number (caddr args))))
(run-server config)))))))
(config-port-set! config (string->number (caddr args))))
(run-server config)))))))
-
;;
(main)
+(main)
-(define (test)
- (run-server (make-config "gopher-root" "localhost" 70 #t)))
+
;;
(define (test)
+
;;
(run-server (make-config "gopher-root" "localhost" 70 #t)))
;; (test)
;; (test)