summaryrefslogtreecommitdiff
path: root/textcode.h
diff options
context:
space:
mode:
authorFelix von Leitner <felix-libowfat@fefe.de>2002-04-30 12:11:36 +0000
committerFelix von Leitner <felix-libowfat@fefe.de>2002-04-30 12:11:36 +0000
commitb0a0b720577506a67244db1617a01e8879188d87 (patch)
treec6fb4aef0addcec2c9111ce6dc3c81b0dc181a20 /textcode.h
parent2969eaa2d7ce6db23fde7a60cf51cc5ad2cf5cca (diff)
downloadlibowfat-b0a0b720577506a67244db1617a01e8879188d87.tar.gz
libowfat-b0a0b720577506a67244db1617a01e8879188d87.zip
add urlencode API
Diffstat (limited to 'textcode.h')
-rw-r--r--textcode.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/textcode.h b/textcode.h
index 85ae0d9..10afe6d 100644
--- a/textcode.h
+++ b/textcode.h
@@ -1,14 +1,21 @@
#ifndef TEXTCODE_H
#define TEXTCODE_H
+/* These take len bytes from src and write them in encoded form to
+ * dest (if dest != NULL), returning the number of bytes written. */
unsigned int fmt_uuencoded(char* dest,const char* src,unsigned int len);
unsigned int fmt_base64(char* dest,const char* src,unsigned int len);
unsigned int fmt_quotedprintable(char* dest,const char* src,unsigned int len);
+unsigned int fmt_urlencode(char* dest,const char* src,unsigned int len);
unsigned int fmt_yenc(char* dest,const char* src,unsigned int len);
+/* These read one line from src, decoded it, and write the result to
+ * dest. The number of decoded bytes is written to destlen. dest
+ * should be able to hold destlen bytes as a rule of thumb. */
unsigned int scan_uuencoded(const char *src,char *dest,unsigned int *destlen);
unsigned int scan_base64(const char *src,char *dest,unsigned int *destlen);
unsigned int scan_quotedprintable(const char *src,char *dest,unsigned int *destlen);
+unsigned int scan_urlencode(const char *src,char *dest,unsigned int *destlen);
unsigned int scan_yenc(const char *src,char *dest,unsigned int *destlen);
#endif