]> code.citadel.org Git - citadel.git/blobdiff - libcitadel/lib/libcitadel.h
* add StrBufSanitizeEmailRecipientVector(); it will qp encode plain names with utf...
[citadel.git] / libcitadel / lib / libcitadel.h
index 4904ff760ce01240ff6e8305af9832ebe8ff2f65..92ab07f3ee096d78c23ed59b9e5a8c90867c395d 100644 (file)
@@ -266,6 +266,10 @@ void StrBuf_RFC822_to_Utf8(StrBuf *Target, const StrBuf *DecodeMe, const StrBuf*
 int StrBufDecodeBase64(StrBuf *Buf);
 int StrBufDecodeHex(StrBuf *Buf);
 int StrBufRFC2047encode(StrBuf **target, const StrBuf *source);
+StrBuf *StrBufSanitizeEmailRecipientVector(const StrBuf *Recp, 
+                                          StrBuf *UserName, 
+                                          StrBuf *EmailAddress,
+                                          StrBuf *EncBuf);
 int StrBufSanitizeAscii(StrBuf *Buf, const char Mute);
 #define LB                     (1)             /* Internal escape chars */
 #define RB                     (2)
@@ -316,7 +320,7 @@ void remove_token(char *source, int parmnum, char separator);
 void fmt_date(char *buf, size_t n, time_t thetime, int seconds);
 int is_msg_in_sequence_set(const char *mset, long msgnum);
 const char *memreadline(const char *start, char *buf, int maxlen);
-char *memreadlinelen(char *start, char *buf, int maxlen, int *retlen);
+const char *memreadlinelen(const char *start, char *buf, int maxlen, int *retlen);
 #define IsEmptyStr(a) ((a)[0] == '\0')
 #define num_parms(source)              num_tokens(source,(char)'|')
 int stripout(char *str, char leftboundary, char rightboundary);
@@ -402,6 +406,8 @@ int GetHashPosFromKey(HashList *Hash, const char *HKey, long HKLen, HashPos *At)
 int DeleteEntryFromHash(HashList *Hash, HashPos *At);
 int GetHashPosCounter(HashList *Hash, HashPos *At);
 void DeleteHashPos(HashPos **DelMe);
+int NextHashPos(HashList *Hash, HashPos *At);
+int GetHashPos(HashList *Hash, HashPos *At, long *HKLen, const char **HashKey, void **Data);
 int GetNextHashPos(HashList *Hash, HashPos *At, long *HKLen, const char **HashKey, void **Data);
 int GetHashAt(HashList *Hash,long At, long *HKLen, const char **HashKey, void **Data);
 void SortByHashKey(HashList *Hash, int Order);
@@ -409,12 +415,12 @@ void SortByHashKeyStr(HashList *Hash);
 int GetCount(HashList *Hash);
 const void *GetSearchPayload(const void *HashVoid);
 void SortByPayload(HashList *Hash, CompareFunc SortBy);
-void generic_free_handler(void *ptr);
 void reference_free_handler(void *ptr);
 int HashLittle(const void *key, size_t length);
 
 
 void convert_spaces_to_underscores(char *str);
+int CheckEncode(const char *pch, long len, const char *pche);
 
 /*
  * Convert 4 bytes char into an Integer.