diff options
author | Jeremy Harris <jgh146exb@wizmail.org> | 2017-02-26 18:53:06 +0000 |
---|---|---|
committer | Jeremy Harris <jgh146exb@wizmail.org> | 2017-02-26 19:01:07 +0000 |
commit | 8de9db65575ccd8013753bb3d23426f0da2a669a (patch) | |
tree | 85f00f853a28504286c6cad88bdf630e772651d7 /doc | |
parent | 4bb432cb42d990bc40665d38aedbf02b00128df7 (diff) |
Add option to control use of shutdown by ${readsocket }. Bug 400
Diffstat (limited to 'doc')
-rw-r--r-- | doc/doc-docbook/spec.xfpt | 13 | ||||
-rw-r--r-- | doc/doc-txt/NewStuff | 3 |
2 files changed, 15 insertions, 1 deletions
diff --git a/doc/doc-docbook/spec.xfpt b/doc/doc-docbook/spec.xfpt index 8b20910c1..054a135b9 100644 --- a/doc/doc-docbook/spec.xfpt +++ b/doc/doc-docbook/spec.xfpt @@ -9767,7 +9767,7 @@ locks out the use of this expansion item in filter files. .vitem "&*${readsocket{*&<&'name'&>&*}{*&<&'request'&>&*}&&& - {*&<&'timeout'&>&*}{*&<&'eol&~string'&>&*}{*&<&'fail&~string'&>&*}}*&" + {*&<&'options'&>&*}{*&<&'eol&~string'&>&*}{*&<&'fail&~string'&>&*}}*&" .cindex "expansion" "inserting from a socket" .cindex "socket, use of in expansion" .cindex "&%readsocket%& expansion item" @@ -9797,6 +9797,17 @@ extend what can be done. Firstly, you can vary the timeout. For example: .code ${readsocket{/socket/name}{request string}{3s}} .endd +.new +The third argument is a list of options, of which the first element is the timeout +and must be present if the argument is given. +Further elements are options of form &'name=value'&. +One option type is currently recognised, defining whether (the default) +or not a shutdown is done on the connection after sending the request. +Example, to not do so (preferred, eg. by some webservers): +.code +${readsocket{/socket/name}{request string}{3s:shutdown=no}} +.endd +.wen A fourth argument allows you to change any newlines that are in the data that is read, in the same way as for &%readfile%& (see above). This example turns them into spaces: diff --git a/doc/doc-txt/NewStuff b/doc/doc-txt/NewStuff index 2a8e520c6..efb8592cf 100644 --- a/doc/doc-txt/NewStuff +++ b/doc/doc-txt/NewStuff @@ -12,6 +12,9 @@ Version 4.90 1. PKG_CONFIG_PATH can now be set in Local/Makefile; wildcards will be expanded, values are collapsed. + 2. The ${readsocket } expansion now takes an option to not shutdown the + connection after sending the query string. The default remains to do so. + Version 4.89 ------------ |