projects
/
yaz-moved-to-github.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
49eef90
)
Function encode_uri_char does not hex encode unreserved chars (RFC 2396
author
Adam Dickmeiss
<adam@indexdata.dk>
Thu, 24 May 2007 10:18:36 +0000
(10:18 +0000)
committer
Adam Dickmeiss
<adam@indexdata.dk>
Thu, 24 May 2007 10:18:36 +0000
(10:18 +0000)
section 2.3).
src/srwutil.c
patch
|
blob
|
history
diff --git
a/src/srwutil.c
b/src/srwutil.c
index
96426ca
..
b115ffc
100644
(file)
--- a/
src/srwutil.c
+++ b/
src/srwutil.c
@@
-2,7
+2,7
@@
* Copyright (C) 1995-2007, Index Data ApS
* See the file LICENSE for details.
*
* Copyright (C) 1995-2007, Index Data ApS
* See the file LICENSE for details.
*
- * $Id: srwutil.c,v 1.58 2007-05-23 13:11:11 adam Exp $
+ * $Id: srwutil.c,v 1.59 2007-05-24 10:18:36 adam Exp $
*/
/**
* \file srwutil.c
*/
/**
* \file srwutil.c
@@
-28,8
+28,9
@@
void encode_uri_char(char *dst, char ch)
{
if (ch == ' ')
strcpy(dst, "+");
{
if (ch == ' ')
strcpy(dst, "+");
+ /* mark = "-" | "_" | "." | "!" | "~" | "*" | "'" | "(" | ")" */
else if ((ch >= 'A' && ch <= 'Z') || (ch >= 'a' && ch <= 'z') ||
else if ((ch >= 'A' && ch <= 'Z') || (ch >= 'a' && ch <= 'z') ||
- (ch >= '0' && ch <= '9'))
+ (ch >= '0' && ch <= '9') || strchr("-_.!~*'(|)", ch))
{
dst[0] = ch;
dst[1] = '\0';
{
dst[0] = ch;
dst[1] = '\0';