-rw-r--r-- | net-im/jabberd/Manifest | 18 | ||||
-rw-r--r-- | net-im/jabberd/files/digest-jabberd-2.1.11-r1 (renamed from net-im/jabberd/files/digest-jabberd-2.1.11) | 0 | ||||
-rw-r--r-- | net-im/jabberd/files/jabberd-2.1.11-r1.patch | 251 | ||||
-rw-r--r-- | net-im/jabberd/jabberd-2.1.11-r1.ebuild (renamed from net-im/jabberd/jabberd-2.1.11.ebuild) | 15 |
4 files changed, 275 insertions, 9 deletions
diff --git a/net-im/jabberd/Manifest b/net-im/jabberd/Manifest index 39ed68c..9af6591 100644 --- a/net-im/jabberd/Manifest +++ b/net-im/jabberd/Manifest | |||
@@ -1,24 +1,28 @@ | |||
1 | AUX jabberd-2.1.11-r1.patch 9979 RMD160 bbd543765e41264e544948983e7193b8d50b9b88 SHA1 4e2b56baf5167ec0b3df31757bfe635a58055b55 SHA256 1b5dace5ba604a37e40637ff22eb856daad4f8504fff5337ffb9ffd77298d3bc | ||
2 | MD5 2ee77f6ead80438a246b58de2b0ab73f files/jabberd-2.1.11-r1.patch 9979 | ||
3 | RMD160 bbd543765e41264e544948983e7193b8d50b9b88 files/jabberd-2.1.11-r1.patch 9979 | ||
4 | SHA256 1b5dace5ba604a37e40637ff22eb856daad4f8504fff5337ffb9ffd77298d3bc files/jabberd-2.1.11-r1.patch 9979 | ||
1 | AUX jabberd-2.1.11.init 1404 RMD160 d93784cc30f573f20cd411a1a18578db46121b26 SHA1 ce0e735adbf539c809568aa2c1d3ee49f565600c SHA256 e9d004e8d83cc59f964b49c44aaf64445593ba8157d4b51df83e5e50f4625094 | 5 | AUX jabberd-2.1.11.init 1404 RMD160 d93784cc30f573f20cd411a1a18578db46121b26 SHA1 ce0e735adbf539c809568aa2c1d3ee49f565600c SHA256 e9d004e8d83cc59f964b49c44aaf64445593ba8157d4b51df83e5e50f4625094 |
2 | MD5 eacd752c3b8eb5f2d4914ca8b3580893 files/jabberd-2.1.11.init 1404 | 6 | MD5 eacd752c3b8eb5f2d4914ca8b3580893 files/jabberd-2.1.11.init 1404 |
3 | RMD160 d93784cc30f573f20cd411a1a18578db46121b26 files/jabberd-2.1.11.init 1404 | 7 | RMD160 d93784cc30f573f20cd411a1a18578db46121b26 files/jabberd-2.1.11.init 1404 |
4 | SHA256 e9d004e8d83cc59f964b49c44aaf64445593ba8157d4b51df83e5e50f4625094 files/jabberd-2.1.11.init 1404 | 8 | SHA256 e9d004e8d83cc59f964b49c44aaf64445593ba8157d4b51df83e5e50f4625094 files/jabberd-2.1.11.init 1404 |
5 | AUX jabberd-2.1.11.pamd 158 RMD160 3143cb1689fbebb51c0d72fa4c6b79ee9c015185 SHA1 5a95607d50b470107e9a0556fb4591688faff02c SHA256 eba4b5cc68b3dd327cfa1afdadbe5adf6d9383f4c79c7661169a4339e40b9a7b | 9 | AUX jabberd-2.1.11.pamd 158 RMD160 3143cb1689fbebb51c0d72fa4c6b79ee9c015185 SHA1 5a95607d50b470107e9a0556fb4591688faff02c SHA256 eba4b5cc68b3dd327cfa1afdadbe5adf6d9383f4c79c7661169a4339e40b9a7b |
6 | MD5 ab77cef855566260d6a779d8d77bc78c files/jabberd-2.1.11.pamd 158 | 10 | MD5 ab77cef855566260d6a779d8d77bc78c files/jabberd-2.1.11.pamd 158 |
7 | RMD160 3143cb1689fbebb51c0d72fa4c6b79ee9c015185 files/jabberd-2.1.11.pamd 158 | 11 | RMD160 3143cb1689fbebb51c0d72fa4c6b79ee9c015185 files/jabberd-2.1.11.pamd 158 |
8 | SHA256 eba4b5cc68b3dd327cfa1afdadbe5adf6d9383f4c79c7661169a4339e40b9a7b files/jabberd-2.1.11.pamd 158 | 12 | SHA256 eba4b5cc68b3dd327cfa1afdadbe5adf6d9383f4c79c7661169a4339e40b9a7b files/jabberd-2.1.11.pamd 158 |
9 | DIST jabberd-2.1.11.tar.bz2 1034039 RMD160 540f9f510351c369938005acb7013ea41d77f5b8 SHA1 528df89fd1fc638590811bb4f14b2d0d8a498a56 SHA256 e99a70102896ce28e5e427234ddaa852aacd8a38700264741a40f5781919bea8 | 13 | DIST jabberd-2.1.11.tar.bz2 1034039 RMD160 540f9f510351c369938005acb7013ea41d77f5b8 SHA1 528df89fd1fc638590811bb4f14b2d0d8a498a56 SHA256 e99a70102896ce28e5e427234ddaa852aacd8a38700264741a40f5781919bea8 |
10 | EBUILD jabberd-2.1.11.ebuild 2688 RMD160 f7166de5a66dc79a885c2f2cd610af45502ec2b2 SHA1 6d72283c1aa82882d2705f75b0b1f04c68ab06c0 SHA256 dacb39449544c1a991ab627bdcd6781bc08d171083c9b2a42b398e780c38214e | 14 | EBUILD jabberd-2.1.11-r1.ebuild 2931 RMD160 b853d8d199905d0048a856765aeae27f982453ff SHA1 b0e7159bd13439320fdc4d72c0fe5e4ee8dac6bd SHA256 aa07d173367d7509a04f6482f29c36b9878956fc0542cd65dd539962c97079cb |
11 | MD5 0a085e6e7ae3903b388c469fe60092af jabberd-2.1.11.ebuild 2688 | 15 | MD5 38355a04b1112de9d828ba25118a87ad jabberd-2.1.11-r1.ebuild 2931 |
12 | RMD160 f7166de5a66dc79a885c2f2cd610af45502ec2b2 jabberd-2.1.11.ebuild 2688 | 16 | RMD160 b853d8d199905d0048a856765aeae27f982453ff jabberd-2.1.11-r1.ebuild 2931 |
13 | SHA256 dacb39449544c1a991ab627bdcd6781bc08d171083c9b2a42b398e780c38214e jabberd-2.1.11.ebuild 2688 | 17 | SHA256 aa07d173367d7509a04f6482f29c36b9878956fc0542cd65dd539962c97079cb jabberd-2.1.11-r1.ebuild 2931 |
14 | MISC ChangeLog 15464 RMD160 bac8facc410dced776f4b5d9f0c4b051100f9409 SHA1 2ed0d2fa838de3b4e1d720f577116af6eba842ec SHA256 7ea8ffdf9c099ca3fc43ccb381100ce6b519de8f6bb582305535491373fb8830 | 18 | MISC ChangeLog 15464 RMD160 bac8facc410dced776f4b5d9f0c4b051100f9409 SHA1 2ed0d2fa838de3b4e1d720f577116af6eba842ec SHA256 7ea8ffdf9c099ca3fc43ccb381100ce6b519de8f6bb582305535491373fb8830 |
15 | MD5 e71dbcd3a38fc84fc22dac39a6019359 ChangeLog 15464 | 19 | MD5 e71dbcd3a38fc84fc22dac39a6019359 ChangeLog 15464 |
16 | RMD160 bac8facc410dced776f4b5d9f0c4b051100f9409 ChangeLog 15464 | 20 | RMD160 bac8facc410dced776f4b5d9f0c4b051100f9409 ChangeLog 15464 |
17 | SHA256 7ea8ffdf9c099ca3fc43ccb381100ce6b519de8f6bb582305535491373fb8830 ChangeLog 15464 | 21 | SHA256 7ea8ffdf9c099ca3fc43ccb381100ce6b519de8f6bb582305535491373fb8830 ChangeLog 15464 |
18 | MISC metadata.xml 399 RMD160 e223c713f74619996bc47a70298aa535f6addf09 SHA1 dc9bc290a5ed00f7101aabd3a40b346112eb40eb SHA256 f68b0864864ad54de5cf072835fc9903e709987261ad1fc102afb0019aa52377 | 22 | MISC metadata.xml 399 RMD160 e223c713f74619996bc47a70298aa535f6addf09 SHA1 dc9bc290a5ed00f7101aabd3a40b346112eb40eb SHA256 f68b0864864ad54de5cf072835fc9903e709987261ad1fc102afb0019aa52377 |
19 | MD5 be8887bde84aab1d4ff9d5a0f5d50141 metadata.xml 399 | 23 | MD5 be8887bde84aab1d4ff9d5a0f5d50141 metadata.xml 399 |
20 | RMD160 e223c713f74619996bc47a70298aa535f6addf09 metadata.xml 399 | 24 | RMD160 e223c713f74619996bc47a70298aa535f6addf09 metadata.xml 399 |
21 | SHA256 f68b0864864ad54de5cf072835fc9903e709987261ad1fc102afb0019aa52377 metadata.xml 399 | 25 | SHA256 f68b0864864ad54de5cf072835fc9903e709987261ad1fc102afb0019aa52377 metadata.xml 399 |
22 | MD5 c07f7b9a6581fa2f5ea895378ce7f7de files/digest-jabberd-2.1.11 250 | 26 | MD5 c07f7b9a6581fa2f5ea895378ce7f7de files/digest-jabberd-2.1.11-r1 250 |
23 | RMD160 cb7aaed13753b29cc9f5a1bce8487647ae3a39f2 files/digest-jabberd-2.1.11 250 | 27 | RMD160 cb7aaed13753b29cc9f5a1bce8487647ae3a39f2 files/digest-jabberd-2.1.11-r1 250 |
24 | SHA256 6d1563e8ca5a90c87768d01e273bfd6cfbe11c93ff70249fb71eeb074b090a39 files/digest-jabberd-2.1.11 250 | 28 | SHA256 6d1563e8ca5a90c87768d01e273bfd6cfbe11c93ff70249fb71eeb074b090a39 files/digest-jabberd-2.1.11-r1 250 |
diff --git a/net-im/jabberd/files/digest-jabberd-2.1.11 b/net-im/jabberd/files/digest-jabberd-2.1.11-r1 index ae7be5e..ae7be5e 100644 --- a/net-im/jabberd/files/digest-jabberd-2.1.11 +++ b/net-im/jabberd/files/digest-jabberd-2.1.11-r1 | |||
diff --git a/net-im/jabberd/files/jabberd-2.1.11-r1.patch b/net-im/jabberd/files/jabberd-2.1.11-r1.patch new file mode 100644 index 0000000..441163c --- a/dev/null +++ b/net-im/jabberd/files/jabberd-2.1.11-r1.patch | |||
@@ -0,0 +1,251 @@ | |||
1 | diff --git a/c2s/main.c b/c2s/main.c | ||
2 | index a86e571..0bf89e6 100644 | ||
3 | --- a/c2s/main.c | ||
4 | +++ b/c2s/main.c | ||
5 | @@ -698,6 +698,7 @@ JABBER_MAIN("jabberd2c2s", "Jabber 2 C2S", "Jabber Open Source Server: Client to | ||
6 | if(sess->ip != NULL) free(sess->ip); | ||
7 | if(sess->result != NULL) nad_free(sess->result); | ||
8 | if(sess->jid != NULL) jid_free(sess->jid); | ||
9 | + if(sess->rate != NULL) rate_free(sess->rate); | ||
10 | |||
11 | free(sess); | ||
12 | } | ||
13 | diff --git a/configure.ac b/configure.ac | ||
14 | index 099aec9..29dca26 100644 | ||
15 | --- a/configure.ac | ||
16 | +++ b/configure.ac | ||
17 | @@ -494,37 +494,48 @@ AM_CONDITIONAL(STORAGE_MYSQL, [test "x-$have_mysql" = "x-yes"]) | ||
18 | |||
19 | # PostgreSQL | ||
20 | AC_ARG_ENABLE([pgsql], | ||
21 | - AC_HELP_STRING([--enable-pgsql], [enable PostgreSQL auth/reg/storage support (no)]), | ||
22 | - [enable_pgsql=$enableval have_pgsql=no], | ||
23 | + AC_HELP_STRING([--enable-pgsql], | ||
24 | +[enable PostgreSQL auth/reg/storage support, you can provide path to | ||
25 | +pg_config executable (no)]), | ||
26 | + [enable_pgsql="$enableval" have_pgsql=no], | ||
27 | [enable_pgsql=no have_pgsql=no]) | ||
28 | -if test "x-$enable_pgsql" = "x-yes" ; then | ||
29 | - for i in /usr /usr/local /usr/local/pgsql ; do | ||
30 | - for j in include include/pgsql include/postgres include/postgresql "" ; do | ||
31 | - if test -r "$i/$j/libpq-fe.h" ; then | ||
32 | - PGSQL_INCLUDE=$i/$j | ||
33 | - fi | ||
34 | - done | ||
35 | - for lib in lib lib64 ; do | ||
36 | - for j in $lib $lib/pgsql $lib/postgres $lib/postgresql "" ; do | ||
37 | - if test -f "$i/$j/libpq.so" || test -f "$i/$j/libpq.a" ; then | ||
38 | - PGSQL_LIBDIR=$i/$j | ||
39 | - fi | ||
40 | - done | ||
41 | - done | ||
42 | - done | ||
43 | - AC_CHECK_LIB([pq], [PQsetdbLogin], [ | ||
44 | - have_pgsql=yes | ||
45 | - if test "x-$PGSQL_INCLUDE" != "x-"; then | ||
46 | - PGSQL_CFLAGS="-I $PGSQL_INCLUDE" | ||
47 | - fi | ||
48 | - if test "x-$PGSQL_LIBDIR" != "x-"; then | ||
49 | - PGSQL_LIBS="-L$PGSQL_LIBDIR -lpq" | ||
50 | - fi | ||
51 | - AC_DEFINE(STORAGE_POSTGRES, 1, [Define to 1 if you want to use PostgreSQL for storage.]) | ||
52 | - ]) | ||
53 | - if test "x-$have_pgsql" != "x-yes" ; then | ||
54 | - AC_MSG_ERROR([PostgreSQL support requested, but headers/libraries not found.]) | ||
55 | - fi | ||
56 | +if test "x-$enable_pgsql" != "x-no" ; then | ||
57 | +if test -x "$enable_pgsql" ; then | ||
58 | + PGSQL_INCLUDE="$($enable_pgsql --includedir)" | ||
59 | + PGSQL_LIBDIR="$($enable_pgsql --libdir)" | ||
60 | + PGSQL_CFLAGS="-I$PGSQL_INCLUDE" | ||
61 | + PGSQL_LIBS="-L$PGSQL_LIBDIR -lpq" | ||
62 | + have_pgsql=yes | ||
63 | + AC_DEFINE([STORAGE_POSTGRES],[1],[Define to 1 if you want to use PostgreSQL for storage.]) | ||
64 | + else# leave legacy detection intact for now | ||
65 | + for i in /usr /usr/local /usr/local/pgsql ; do | ||
66 | + for j in include include/pgsql include/postgres include/postgresql "" ; do | ||
67 | + if test -r "$i/$j/libpq-fe.h" ; then | ||
68 | + PGSQL_INCLUDE=$i/$j | ||
69 | + fi | ||
70 | + done | ||
71 | + for lib in lib lib64 ; do | ||
72 | + for j in $lib $lib/pgsql $lib/postgres $lib/postgresql "" ; do | ||
73 | + if test -f "$i/$j/libpq.so" || test -f "$i/$j/libpq.a" ; then | ||
74 | + PGSQL_LIBDIR=$i/$j | ||
75 | + fi | ||
76 | + done | ||
77 | + done | ||
78 | + done | ||
79 | + AC_CHECK_LIB([pq], [PQsetdbLogin], [ | ||
80 | + have_pgsql=yes | ||
81 | + if test "x-$PGSQL_INCLUDE" != "x-"; then | ||
82 | + PGSQL_CFLAGS="-I $PGSQL_INCLUDE" | ||
83 | + fi | ||
84 | + if test "x-$PGSQL_LIBDIR" != "x-"; then | ||
85 | + PGSQL_LIBS="-L$PGSQL_LIBDIR -lpq" | ||
86 | + fi | ||
87 | + AC_DEFINE(STORAGE_POSTGRES, 1, [Define to 1 if you want to use PostgreSQL for storage.]) | ||
88 | + ]) | ||
89 | + if test "x-$have_pgsql" != "x-yes" ; then | ||
90 | + AC_MSG_ERROR([PostgreSQL support requested, but headers/libraries not found.]) | ||
91 | + fi | ||
92 | +fi | ||
93 | fi | ||
94 | AC_SUBST(PGSQL_CFLAGS) | ||
95 | AC_SUBST(PGSQL_LIBS) | ||
96 | diff --git a/mio/mio_impl.h b/mio/mio_impl.h | ||
97 | index 6f72a5c..cabdc67 100644 | ||
98 | --- a/mio/mio_impl.h | ||
99 | +++ b/mio/mio_impl.h | ||
100 | @@ -226,8 +226,12 @@ static void _mio_run(mio_t m, int timeout) | ||
101 | { | ||
102 | mio_fd_t fd = MIO_ITERATOR_FD(m,iter); | ||
103 | |||
104 | - /* skip dead slots */ | ||
105 | - if(FD(m,fd)->type == type_CLOSED) continue; | ||
106 | + /* deferred closing fd */ | ||
107 | + if(FD(m,fd)->type == type_CLOSED) | ||
108 | + { | ||
109 | + MIO_FREE_FD(m, fd); | ||
110 | + continue; | ||
111 | + } | ||
112 | |||
113 | /* new conns on a listen socket */ | ||
114 | if(FD(m,fd)->type == type_LISTEN && MIO_CAN_READ(m,iter)) | ||
115 | @@ -259,12 +263,6 @@ static void _mio_run(mio_t m, int timeout) | ||
116 | if(ACT(m, fd, action_WRITE, NULL) == 0) | ||
117 | MIO_UNSET_WRITE(m, FD(m,fd)); | ||
118 | } | ||
119 | - | ||
120 | - /* deferred closing fd */ | ||
121 | - if(FD(m,fd)->type == type_CLOSED) | ||
122 | - { | ||
123 | - MIO_FREE_FD(m, fd); | ||
124 | - } | ||
125 | } | ||
126 | } | ||
127 | |||
128 | diff --git a/sm/main.c b/sm/main.c | ||
129 | index 2f1439d..9f27829 100644 | ||
130 | --- a/sm/main.c | ||
131 | +++ b/sm/main.c | ||
132 | @@ -392,6 +392,7 @@ JABBER_MAIN("jabberd2sm", "Jabber 2 Session Manager", "Jabber Open Source Server | ||
133 | xhash_free(sm->acls); | ||
134 | xhash_free(sm->features); | ||
135 | xhash_free(sm->xmlns); | ||
136 | + xhash_free(sm->xmlns_refcount); | ||
137 | xhash_free(sm->users); | ||
138 | |||
139 | sx_free(sm->router); | ||
140 | diff --git a/sm/mod_privacy.c b/sm/mod_privacy.c | ||
141 | index 06f9e6e..5abf065 100644 | ||
142 | --- a/sm/mod_privacy.c | ||
143 | +++ b/sm/mod_privacy.c | ||
144 | @@ -205,7 +205,7 @@ static int _privacy_user_load(mod_instance_t mi, user_t user) { | ||
145 | continue; | ||
146 | } | ||
147 | |||
148 | - pool_cleanup(zlist->p, free, zitem->jid); | ||
149 | + pool_cleanup(zlist->p, jid_free, zitem->jid); | ||
150 | |||
151 | log_debug(ZONE, "jid item with value '%s'", jid_full(zitem->jid)); | ||
152 | |||
153 | @@ -696,7 +696,7 @@ static mod_ret_t _privacy_in_sess(mod_instance_t mi, sess_t sess, pkt_t pkt) { | ||
154 | return -stanza_err_BAD_REQUEST; | ||
155 | } | ||
156 | |||
157 | - pool_cleanup(p, free, zitem->jid); | ||
158 | + pool_cleanup(p, jid_free, zitem->jid); | ||
159 | |||
160 | log_debug(ZONE, "jid item with value '%s'", jid_full(zitem->jid)); | ||
161 | |||
162 | diff --git a/storage/authreg_pgsql.c b/storage/authreg_pgsql.c | ||
163 | index 1f15e83..8d3cf88 100644 | ||
164 | --- a/storage/authreg_pgsql.c | ||
165 | +++ b/storage/authreg_pgsql.c | ||
166 | @@ -304,7 +304,7 @@ int _ar_pgsql_check_sql( authreg_t ar, char * sql, char * types ) { | ||
167 | |||
168 | /** start me up */ | ||
169 | int ar_init(authreg_t ar) { | ||
170 | - char *host, *port, *dbname, *user, *pass; | ||
171 | + char *host, *port, *dbname, *user, *pass, *conninfo; | ||
172 | char *create, *select, *setpassword, *delete; | ||
173 | char *table, *username, *realm; | ||
174 | char *template; | ||
175 | @@ -391,15 +391,22 @@ int ar_init(authreg_t ar) { | ||
176 | free(setpassword); | ||
177 | free(delete); | ||
178 | |||
179 | - host = config_get_one(ar->c2s->config, "authreg.pgsql.host", 0); | ||
180 | - port = config_get_one(ar->c2s->config, "authreg.pgsql.port", 0); | ||
181 | - dbname = config_get_one(ar->c2s->config, "authreg.pgsql.dbname", 0); | ||
182 | - user = config_get_one(ar->c2s->config, "authreg.pgsql.user", 0); | ||
183 | - pass = config_get_one(ar->c2s->config, "authreg.pgsql.pass", 0); | ||
184 | - | ||
185 | - log_debug( ZONE, "pgsql connecting as '%s' to database '%s' on %s:%s", user, dbname, host, port ); | ||
186 | + conninfo = config_get_one(ar->c2s->config,"authreg.pgsql.conninfo",0); | ||
187 | + if(conninfo) { | ||
188 | +conn = PQconnect(conninfo); | ||
189 | +/* don't log connection info for it can contain password */ | ||
190 | +log_debug( ZONE, "pgsql connecting to the databse"); | ||
191 | + }else{ | ||
192 | +/* compatibility settings */ | ||
193 | +host = config_get_one(ar->c2s->config, "authreg.pgsql.host", 0); | ||
194 | +port = config_get_one(ar->c2s->config, "authreg.pgsql.port", 0); | ||
195 | +dbname = config_get_one(ar->c2s->config, "authreg.pgsql.dbname", 0); | ||
196 | +user = config_get_one(ar->c2s->config, "authreg.pgsql.user", 0); | ||
197 | +pass = config_get_one(ar->c2s->config, "authreg.pgsql.pass", 0); | ||
198 | +log_debug( ZONE, "pgsql connecting as '%s' to database '%s' on %s:%s", user, dbname, host, port ); | ||
199 | +conn = PQsetdbLogin(host, port, NULL, NULL, dbname, user, pass); | ||
200 | + } | ||
201 | |||
202 | - conn = PQsetdbLogin(host, port, NULL, NULL, dbname, user, pass); | ||
203 | if(conn == NULL) { | ||
204 | log_write(ar->c2s->log, LOG_ERR, "pgsql: unable to allocate database connection state"); | ||
205 | return 1; | ||
206 | diff --git a/sx/sasl_gsasl.c b/sx/sasl_gsasl.c | ||
207 | index 69eeec2..0036c0f 100644 | ||
208 | --- a/sx/sasl_gsasl.c | ||
209 | +++ b/sx/sasl_gsasl.c | ||
210 | @@ -338,6 +338,7 @@ static void _sx_sasl_client_process(sx_t s, sx_plugin_t p, Gsasl_session *sd, ch | ||
211 | if(ret != GSASL_OK && ret != GSASL_NEEDS_MORE) { | ||
212 | _sx_debug(ZONE, "gsasl_step failed, no sasl for this conn; (%d): %s", ret, gsasl_strerror(ret)); | ||
213 | _sx_nad_write(s, _sx_sasl_failure(s, _sasl_err_MALFORMED_REQUEST), 0); | ||
214 | + if(buf != NULL) free(buf); | ||
215 | return; | ||
216 | } | ||
217 | } | ||
218 | @@ -350,6 +351,7 @@ static void _sx_sasl_client_process(sx_t s, sx_plugin_t p, Gsasl_session *sd, ch | ||
219 | if(ret != GSASL_OK && ret != GSASL_NEEDS_MORE) { | ||
220 | _sx_debug(ZONE, "gsasl_step failed, no sasl for this conn; (%d): %s", ret, gsasl_strerror(ret)); | ||
221 | _sx_nad_write(s, _sx_sasl_failure(s, _sasl_err_MALFORMED_REQUEST), 0); | ||
222 | + if(buf != NULL) free(buf); | ||
223 | return; | ||
224 | } | ||
225 | |||
226 | diff --git a/util/jid.c b/util/jid.c | ||
227 | index 695b15f..f4b0021 100644 | ||
228 | --- a/util/jid.c | ||
229 | +++ b/util/jid.c | ||
230 | @@ -332,7 +332,7 @@ static jid_t jid_reset_components_internal(jid_t jid, const unsigned char *node, | ||
231 | else { | ||
232 | /* allocate new data buffer */ | ||
233 | jid->jid_data_len = node_l+domain_l+resource_l+3; | ||
234 | - jid->jid_data = malloc(jid->jid_data_len); | ||
235 | + jid->jid_data = realloc(jid->jid_data, jid->jid_data_len); | ||
236 | } | ||
237 | |||
238 | /* copy to buffer */ | ||
239 | diff --git a/util/nad.c b/util/nad.c | ||
240 | index 2ac8670..eec3c17 100644 | ||
241 | --- a/util/nad.c | ||
242 | +++ b/util/nad.c | ||
243 | @@ -61,7 +61,7 @@ static void _nad_ptr_check(const char *func, nad_t nad) { | ||
244 | #define _nad_ptr_check(func,nad) | ||
245 | #endif | ||
246 | |||
247 | -#define BLOCKSIZE 1024 | ||
248 | +#define BLOCKSIZE 128 | ||
249 | |||
250 | /** internal: do and return the math and ensure it gets realloc'd */ | ||
251 | static int _nad_realloc(void **oblocks, int len) | ||
diff --git a/net-im/jabberd/jabberd-2.1.11.ebuild b/net-im/jabberd/jabberd-2.1.11-r1.ebuild index c4b19cb..9445d07 100644 --- a/net-im/jabberd/jabberd-2.1.11.ebuild +++ b/net-im/jabberd/jabberd-2.1.11-r1.ebuild | |||
@@ -1,62 +1,73 @@ | |||
1 | # Copyright 1999-2007 Gentoo Foundation | 1 | # Copyright 1999-2007 Gentoo Foundation |
2 | # Distributed under the terms of the GNU General Public License v2 | 2 | # Distributed under the terms of the GNU General Public License v2 |
3 | # $Header: $ | 3 | # $Header: $ |
4 | 4 | ||
5 | inherit pam eutils | 5 | WANT_AUTOCONF="lastest" |
6 | WANT_AUTOMAKE="none" | ||
7 | inherit pam eutils postgresql autotools | ||
6 | 8 | ||
7 | DESCRIPTION="Open Source Jabber Server" | 9 | DESCRIPTION="Open Source Jabber Server" |
8 | HOMEPAGE="http://jabberd2.xiaoka.com/" | 10 | HOMEPAGE="http://jabberd2.xiaoka.com/" |
9 | SRC_URI="http://ftp.xiaoka.com/${PN}2/releases/${P}.tar.bz2" | 11 | SRC_URI="http://ftp.xiaoka.com/${PN}2/releases/${P}.tar.bz2" |
10 | 12 | ||
11 | SLOT="0" | 13 | SLOT="0" |
12 | LICENSE="GPL-2" | 14 | LICENSE="GPL-2" |
13 | KEYWORDS="~amd64 ~ppc ~sparc ~x86" | 15 | KEYWORDS="~amd64 ~ppc ~sparc ~x86" |
14 | IUSE="debug memdebug ldap mysql pam pipe postgres sqlite ssl berkdb anon fs" | 16 | IUSE="debug memdebug ldap mysql pam pipe postgres sqlite ssl berkdb anon fs" |
15 | 17 | ||
16 | RDEPEND=">=net-im/jabber-base-0.01 | 18 | RDEPEND=">=net-im/jabber-base-0.01 |
17 | ssl? ( >=dev-libs/openssl-0.9.6b ) | 19 | ssl? ( >=dev-libs/openssl-0.9.6b ) |
18 | idn? ( net-dns/libidn ) | 20 | idn? ( net-dns/libidn ) |
19 | ldap? ( net-nds/openldap ) | 21 | ldap? ( net-nds/openldap ) |
20 | berkdb? ( >=sys-libs/db-4.1.25 ) | 22 | berkdb? ( >=sys-libs/db-4.1.25 ) |
21 | mysql? ( virtual/mysql ) | 23 | mysql? ( virtual/mysql ) |
22 | postgres? ( virtual/postgresql-libs ) | 24 | postgres? ( virtual/postgresql-libs ) |
23 | sqlite? ( =dev-db/sqlite-3* ) | 25 | sqlite? ( =dev-db/sqlite-3* ) |
24 | dev-libs/expat | 26 | dev-libs/expat |
25 | dev-libs/cyrus-sasl" | 27 | dev-libs/cyrus-sasl" |
26 | DEPEND="${RDEPEND}" | 28 | DEPEND="${RDEPEND}" |
27 | 29 | ||
30 | src_unpack() { | ||
31 | unpack $A | ||
32 | cd "$S" | ||
33 | epatch "${FILESDIR}/${PF}.patch" | ||
34 | eautoreconf | ||
35 | } | ||
36 | |||
28 | src_compile() { | 37 | src_compile() { |
29 | 38 | ||
30 | if use memdebug && ! use debug ; then | 39 | if use memdebug && ! use debug ; then |
31 | ewarn '"memdebug" requires "debug"' | 40 | ewarn '"memdebug" requires "debug"' |
32 | fi | 41 | fi |
33 | 42 | ||
43 | local pgconfigbin | ||
44 | use postgres && pgconfigbin="$(postgresql_get_pgconfig)" | ||
34 | # gsasl backend is disabled due to the lack of proper gsasl in the tree | 45 | # gsasl backend is disabled due to the lack of proper gsasl in the tree |
35 | # TODO: rework postgres part in configure.ac | 46 | # TODO: rework postgres part in configure.ac |
36 | # TODO: conditionally add extra include path for db_includedir from | 47 | # TODO: conditionally add extra include path for db_includedir from |
37 | # db-use.eclass | 48 | # db-use.eclass |
38 | econf \ | 49 | econf \ |
39 | --localstatedir=/var \ | 50 | --localstatedir=/var \ |
40 | --sysconfdir=/etc/jabber \ | 51 | --sysconfdir=/etc/jabber \ |
41 | $(use_enable debug) \ | 52 | $(use_enable debug) \ |
42 | $(use_enable memdebug nad-debug) $(use_enable memdebug pool-debug) \ | 53 | $(use_enable memdebug nad-debug) $(use_enable memdebug pool-debug) \ |
43 | --enable-sasl=cyrus \ | 54 | --enable-sasl=cyrus \ |
44 | $(use_enable ssl) \ | 55 | $(use_enable ssl) \ |
45 | $(use_enable mysql) \ | 56 | $(use_enable mysql) \ |
46 | $(use_enable postgres pgsql) \ | 57 | $(use_enable postgres pgsql "$pgconfigbin") \ |
47 | $(use_enable sqlite) \ | 58 | $(use_enable sqlite) \ |
48 | $(use_enable berkdb db) \ | 59 | $(use_enable berkdb db) \ |
49 | $(use_enable ldap) \ | 60 | $(use_enable ldap) \ |
50 | $(use_enable pam) \ | 61 | $(use_enable pam) \ |
51 | $(use_enable pipe) \ | 62 | $(use_enable pipe) \ |
52 | $(use_enable anon) \ | 63 | $(use_enable anon) \ |
53 | $(use_enable fs) \ | 64 | $(use_enable fs) \ |
54 | || die "econf failed" | 65 | || die "econf failed" |
55 | emake || die "make failed" | 66 | emake || die "make failed" |
56 | 67 | ||
57 | } | 68 | } |
58 | 69 | ||
59 | src_install() { | 70 | src_install() { |
60 | 71 | ||
61 | make DESTDIR="${D}" install || die "make install failed" | 72 | make DESTDIR="${D}" install || die "make install failed" |
62 | 73 | ||