[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[GNUnet-SVN] [gnurl] 123/153: gopher: Do not translate `?' to `%09'
From: |
gnunet |
Subject: |
[GNUnet-SVN] [gnurl] 123/153: gopher: Do not translate `?' to `%09' |
Date: |
Tue, 11 Sep 2018 12:53:14 +0200 |
This is an automated email from the git hooks/post-receive script.
ng0 pushed a commit to branch master
in repository gnurl.
commit 8f3c3cd08a5b252002a4abfb19780850fc51040e
Author: Leonardo Taccari <address@hidden>
AuthorDate: Thu Aug 23 23:27:34 2018 +0200
gopher: Do not translate `?' to `%09'
Since GOPHER support was added in curl `?' character was automatically
translated to `%09' (`\t').
However, this behaviour does not seems documented in RFC 4266 and for
search selectors it is documented to directly use `%09' in the URL.
Apart that several gopher servers in the current gopherspace have CGI
support where `?' is used as part of the selector and translating it to
`%09' often leads to surprising results.
Closes #2910
---
lib/gopher.c | 7 -------
tests/data/test1202 | 2 +-
2 files changed, 1 insertion(+), 8 deletions(-)
diff --git a/lib/gopher.c b/lib/gopher.c
index b7c31b695..d65049969 100644
--- a/lib/gopher.c
+++ b/lib/gopher.c
@@ -93,18 +93,11 @@ static CURLcode gopher_do(struct connectdata *conn, bool
*done)
}
else {
char *newp;
- size_t j, i;
/* Otherwise, drop / and the first character (i.e., item type) ... */
newp = path;
newp += 2;
- /* ... then turn ? into TAB for search servers, Veronica, etc. ... */
- j = strlen(newp);
- for(i = 0; i<j; i++)
- if(newp[i] == '?')
- newp[i] = '\x09';
-
/* ... and finally unescape */
result = Curl_urldecode(data, newp, 0, &sel, &len, FALSE);
if(result)
diff --git a/tests/data/test1202 b/tests/data/test1202
index 37d270acb..6c91a774c 100644
--- a/tests/data/test1202
+++ b/tests/data/test1202
@@ -26,7 +26,7 @@ gopher
Gopher query
</name>
<command>
-"gopher://%HOSTIP:%GOPHERPORT/7/the/search/engine?query%20succeeded/1202"
+"gopher://%HOSTIP:%GOPHERPORT/7/the/search/engine%09query%20succeeded/1202"
</command>
</client>
--
To stop receiving notification emails like this one, please contact
address@hidden
- [GNUnet-SVN] [gnurl] 113/153: curl-compilers: enable -Wimplicit-fallthrough=4 for GCC, (continued)
- [GNUnet-SVN] [gnurl] 113/153: curl-compilers: enable -Wimplicit-fallthrough=4 for GCC, gnunet, 2018/09/11
- [GNUnet-SVN] [gnurl] 124/153: schannel: client certificate store opening fix, gnunet, 2018/09/11
- [GNUnet-SVN] [gnurl] 125/153: README: add appveyor build badge [ci skip], gnunet, 2018/09/11
- [GNUnet-SVN] [gnurl] 109/153: x509asn1: make several functions static, gnunet, 2018/09/11
- [GNUnet-SVN] [gnurl] 136/153: Don't use Windows path %PWD for SSH tests, gnunet, 2018/09/11
- [GNUnet-SVN] [gnurl] 147/153: sftp: don't send post-qoute sequence when retrying a connection, gnunet, 2018/09/11
- [GNUnet-SVN] [gnurl] 72/153: README.md: add LGTM.com code quality grade for C/C++, gnunet, 2018/09/11
- [GNUnet-SVN] [gnurl] 107/153: http2: avoid set_stream_user_data() before stream is assigned, gnunet, 2018/09/11
- [GNUnet-SVN] [gnurl] 118/153: http2: abort the send_callback if not setup yet, gnunet, 2018/09/11
- [GNUnet-SVN] [gnurl] 117/153: http2: remove four unused nghttp2 callbacks, gnunet, 2018/09/11
- [GNUnet-SVN] [gnurl] 123/153: gopher: Do not translate `?' to `%09',
gnunet <=
- [GNUnet-SVN] [gnurl] 120/153: RELEASE-NOTES: synced, gnunet, 2018/09/11
- [GNUnet-SVN] [gnurl] 122/153: cookie tests: treat files as text, gnunet, 2018/09/11
- [GNUnet-SVN] [gnurl] 114/153: Enable more GCC warnings, gnunet, 2018/09/11
- [GNUnet-SVN] [gnurl] 119/153: Tests: fixes for Windows, gnunet, 2018/09/11
- [GNUnet-SVN] [gnurl] 121/153: libcurl-thread.3: expand somewhat on the NO_SIGNAL motivation, gnunet, 2018/09/11
- [GNUnet-SVN] [gnurl] 112/153: curl-compilers: enable -Wbad-function-cast on GCC, gnunet, 2018/09/11
- [GNUnet-SVN] [gnurl] 115/153: test1148: disable if decimal separator is not point, gnunet, 2018/09/11
- [GNUnet-SVN] [gnurl] 111/153: configure: conditionally enable pedantic-errors, gnunet, 2018/09/11
- [GNUnet-SVN] [gnurl] 116/153: x509asn1: use FALLTHROUGH, gnunet, 2018/09/11
- [GNUnet-SVN] [gnurl] 100/153: http2: make sure to send after RST_STREAM, gnunet, 2018/09/11