mirror of
https://codeberg.org/cage/tinmop/
synced 2025-01-29 04:09:19 +01:00
- [gemini] percent encoded query.
This commit is contained in:
parent
adb83bf462
commit
f861d80b8c
@ -122,6 +122,7 @@ install_dependency () {
|
||||
--eval "(ql:quickload \"cffi\")" \
|
||||
--eval "(ql:quickload \"babel\")" \
|
||||
--eval "(ql:quickload \"puri\")" \
|
||||
--eval "(ql:quickload \"percent-encoding\")" \
|
||||
--eval "(sb-ext:quit)";
|
||||
}
|
||||
|
||||
|
@ -218,7 +218,7 @@
|
||||
(let* ((uri (make-gemini-uri host path query port))
|
||||
(ctx (cl+ssl:make-context :verify-mode cl+ssl:+ssl-verify-none+)))
|
||||
(when query
|
||||
(setf uri (strcat uri "?" query)))
|
||||
(setf uri (strcat uri "?" (percent-encode query))))
|
||||
(cl+ssl:with-global-context (ctx :auto-free-p t)
|
||||
(let ((socket (usocket:socket-connect host port :element-type '(unsigned-byte 8))))
|
||||
(unwind-protect
|
||||
|
@ -355,7 +355,8 @@
|
||||
:annotated-text-symbol
|
||||
:annotated-text-value
|
||||
:box-fit-multiple-column-annotated
|
||||
:collect-links))
|
||||
:collect-links
|
||||
:percent-encode))
|
||||
|
||||
(defpackage :html-utils
|
||||
(:use
|
||||
|
@ -670,3 +670,6 @@ printed in the box column by column; in the example above the results are:
|
||||
results
|
||||
:test #'string=))
|
||||
results)))
|
||||
|
||||
(defun percent-encode (string)
|
||||
(percent-encoding:encode string :encoding :utf-8))
|
||||
|
@ -50,6 +50,7 @@
|
||||
:usocket
|
||||
:babel
|
||||
:puri
|
||||
:percent-encoding
|
||||
:uiop)
|
||||
:components ((:file "package")
|
||||
(:file "config")
|
||||
|
Loading…
x
Reference in New Issue
Block a user