fdm: new package added

Signed-off-by: Dmitry V. Zimin <pfzim@mail.ru>
This commit is contained in:
Dmitry V. Zimin
2014-11-20 17:41:03 +03:00
parent c950f48e7a
commit c400fe3b09
7 changed files with 742 additions and 0 deletions
+14
View File
@@ -0,0 +1,14 @@
--- a/fdm.h 2011-10-10 17:36:29.000000000 +0400
+++ b/fdm.h 2014-11-13 12:56:59.217083683 +0300
@@ -719,6 +719,11 @@
size_t strlcat(char *, const char *, size_t);
#endif
+int local_b64_ntop(uint8_t const *src, size_t srclength, char *target,
+ size_t targsize);
+
+int local_b64_pton(char const *src, uint8_t *target, size_t targsize);
+
/* shm.c */
char *shm_path(struct shm *);
void *shm_create(struct shm *, size_t);
+20
View File
@@ -0,0 +1,20 @@
--- a/imap-common.c 2011-12-20 00:19:03.000000000 +0400
+++ b/imap-common.c 2014-11-13 12:56:06.930418446 +0300
@@ -206,7 +206,7 @@
size = (strlen(in) * 2) + 1;
out = xcalloc(1, size);
- if (b64_ntop(in, strlen(in), out, size) < 0) {
+ if (local_b64_ntop(in, strlen(in), out, size) < 0) {
xfree(out);
return (NULL);
}
@@ -222,7 +222,7 @@
size = (strlen(in) * 4) + 1;
out = xcalloc(1, size);
- if (b64_pton(in, out, size) < 0) {
+ if (local_b64_pton(in, out, size) < 0) {
xfree(out);
return (NULL);
}