citadel.git
12 years agoFix StrHtmlEcmaEscAppend() more edge cases in utf8 handling
Wilfried Goesgens [Thu, 18 Aug 2011 17:53:18 +0000 (17:53 +0000)]
Fix StrHtmlEcmaEscAppend() more edge cases in utf8 handling

 - Ctdl_GetUtf8SequenceLength(): return 0 for broken, 1 for non-utf8 sequences
 - StrHtmlEcmaEscAppend(): another attempt to fix json appending:
  - use switch instead of Rumpelstilskin if sequence
  - use HKEY for our static sequences
  - don't check for buffer expansion again while utf8-handling; we have 11 bytes reserved, utf8 will at most become 6 bytes
  - Simply handle ASCII chars in the utf8 loop
  - since aptr is moved implicitely, we mustn't move it for the last byte
  - add missing handling for some escapers
  - let unicode escapers pass

Conflicts:

libcitadel/lib/stringbuf.c

12 years ago fix QP encoding
Wilfried Goesgens [Thu, 18 Aug 2011 09:53:01 +0000 (09:53 +0000)]
fix QP encoding

     - once we decided to QP encode we also need to encode = (forgotten in last commit)

12 years agofix QP encoding
Wilfried Goesgens [Thu, 18 Aug 2011 09:14:48 +0000 (09:14 +0000)]
fix QP encoding

 - once we decided to QP encode we also need to encode =[]

12 years agoWork on event'ing the pop3 aggregator
Wilfried Goesgens [Wed, 17 Aug 2011 17:43:15 +0000 (17:43 +0000)]
Work on event'ing the pop3 aggregator

  - POP3_C_ReAttachToFetchMessages(): we manage the transition DB-IO -> Network I/O
  - POP3C_GetListCommandState(): after receiving the list-OK we have to continue reading the list items
  - POP3C_GetListOneLine(): the server sends us the size of the message; save it for later use.
  - POP3C_GetOneMessagID(): after reading all list-items, start DB lookup whether we knew them already.
  - POP3C_GetOneMessageIDState(): if more items are in the list, call us again with the next message ID.
  - POP3_FetchNetworkUsetableEntry(): fetch one UT-entry per call; forward to POP3_C_ReAttachToFetchMessages() once we saw all items in the list.
  - POP3C_SendGetOneMsg(): cycle over the list till we find the next Mail we didn't know already & fetch it; if no more items in list -> goodbuye.
  - POP3C_ReadMessageBody() after the I/O layer read the message from the socket, parse it; move our context over to the DB-Queue.
  - POP3C_ReadMessageBodyFollowing(): On success initialize the async message reader; let the I/O layer read the message, then continue parsing & saving it.
  - POP3C_StoreMsgRead(): parse & save the message to the DB. Continue with remembering it in the UT table.
  - POP3C_SendDelete(): check whether we want to delete the mails on the server, if do; else continue with POP3C_SendGetOneMsg() to fetch next in list.
  - POP3_C_ReadServerStatus(): switch between line based read operation and reading whole messages.

we now can successfully aggregate one pop3 account.

12 years agoadd infrastructure to cleanly swap inbetween the DB and the IO queue; add infrastruct...
Wilfried Goesgens [Wed, 17 Aug 2011 17:18:07 +0000 (17:18 +0000)]
add infrastructure to cleanly swap inbetween the DB and the IO queue; add infrastructure needed for async message reading.

  - QueueDBOperation(): use our own vars on the AsyncIO struct, so we don't overwrite handlers & events from the file I/O stuff.
  - DB_PerformNext(): don't use default: so we get warnings if new states are added and not handled here.
  - DB_PerformNext(): if we don't get a DB query or Terminate, the db operations are done, remove our handlers, this AsyncIO context is handed over into another Queue by the application logic.
  - NextDBOperation(): use our own vars on the AsyncIO struct, so we don't overwrite handlers & events from the file I/O stuff.
  - HandleInbound(): handle more read-states; needed for message reading.
  - HandleInbound(): move Rumpelstilskin lookup if to switch()
  - IO_send_callback(): fix/add IO debugging to /tmp/foo
  - IO_send_callback(): Adjust switch to some edge cases:
    - eSendReply: check whether we're done with sending, if, fall forward to writing.
    - eReadMore: was missing, continue reading (if)
    - eReadPayload: new, read smtp messages for example.
    - eDBQuery: the application logic want to perform database I/O with this context, clean up hooks and remove it from this queue.
  - set_start_callback(): properly hanle the new cases
  - IO_recv_callback(): fix/add IO debugging to /tmp/foo
  - ReAttachIO(): use me if you want to continue with file I/O after i.e. DB-I/O

12 years agoAdd async message reading
Wilfried Goesgens [Wed, 17 Aug 2011 17:13:59 +0000 (17:13 +0000)]
Add async message reading

  - CtdlSubmitMsg(): make param const, since its just read
  - add NewAsyncMsg(): preprocess the parameters provided by application logic, return the worker struct for message reading
  - add CtdlReadMessageBodyAsync(): call me from your IO handler to read a message from the socket asynchroneous.
  - add DeleteAsyncMsg(): call me to delete the worker vars.

12 years agoRename function to cary the module prefix.
Wilfried Goesgens [Wed, 17 Aug 2011 17:09:57 +0000 (17:09 +0000)]
Rename function to cary the module prefix.

12 years agowork on the pop3 aggregator
Wilfried Goesgens [Wed, 10 Aug 2011 14:02:00 +0000 (14:02 +0000)]
work on the pop3 aggregator

  - rewrite the config parser similar to the rss-configparser
  - copy over handler logic from async smtp connector
  - chop worker into handy bits so the handler logic can control it.

12 years agofix naming of functions, so they live in the RSS-Namespace
Wilfried Goesgens [Wed, 10 Aug 2011 14:00:34 +0000 (14:00 +0000)]
fix naming of functions, so they live in the RSS-Namespace

12 years agotiny fixes
Wilfried Goesgens [Wed, 10 Aug 2011 13:59:20 +0000 (13:59 +0000)]
tiny fixes

  - log failed connection attempts
  - add sample to set 127.0.0.1

12 years agofix parsing of IP-Urls
Wilfried Goesgens [Wed, 10 Aug 2011 13:55:42 +0000 (13:55 +0000)]
fix parsing of IP-Urls

  - need to point inet_pton() to the rightly casted pointer in case of non-IPv6
  - set the port using hton()
  - set the protocol depending on our findings

12 years agoStrBufSipLine(): make input params const; fix several warnings about unused code.
Wilfried Goesgens [Sun, 24 Jul 2011 13:35:59 +0000 (13:35 +0000)]
StrBufSipLine(): make input params const; fix several warnings about unused code.

Conflicts:

libcitadel/lib/libcitadel.h

12 years agoDBG_QR[2] now a configurable loggable
Art Cancro [Mon, 18 Jul 2011 20:45:06 +0000 (16:45 -0400)]
DBG_QR[2] now a configurable loggable

12 years agoWrap all calls to pthread_mutex_lock() and pthread_mutex_unlock() within CtdlLogResult()
Art Cancro [Mon, 18 Jul 2011 20:21:29 +0000 (16:21 -0400)]
Wrap all calls to pthread_mutex_lock() and pthread_mutex_unlock() within CtdlLogResult()

12 years agoConvenience function CtdlLogResult()
Art Cancro [Mon, 18 Jul 2011 20:19:45 +0000 (16:19 -0400)]
Convenience function CtdlLogResult()

12 years agofinalize allocation & freeing of rss stuff
Wilfried Goesgens [Sun, 10 Jul 2011 13:40:38 +0000 (13:40 +0000)]
finalize allocation & freeing of rss stuff

12 years agomake shure invalid session fd's don't get set into the central select.
Wilfried Goesgens [Sat, 9 Jul 2011 20:50:48 +0000 (20:50 +0000)]
make shure invalid session fd's don't get set into the central select.

12 years agouse right struct for memset.
Wilfried Goesgens [Sat, 9 Jul 2011 20:50:33 +0000 (20:50 +0000)]
use right struct for memset.

12 years agowork on making RSS aggregator instances and roomlists consistant.
Wilfried Goesgens [Thu, 7 Jul 2011 22:37:22 +0000 (22:37 +0000)]
work on making RSS aggregator instances and roomlists consistant.

12 years agoFix documentation
Wilfried Goesgens [Thu, 7 Jul 2011 19:50:26 +0000 (19:50 +0000)]
Fix documentation

  - fix bug about escaping in strbuf
  - link Hashlist Componets to groups so they can be easily accessed.

12 years agofix conditions where several rooms read the same RSS feed
Wilfried Goesgens [Sun, 3 Jul 2011 22:35:27 +0000 (22:35 +0000)]
fix conditions where several rooms read the same RSS feed

12 years agomerge in euid generation from master
Wilfried Goesgens [Sun, 3 Jul 2011 22:34:03 +0000 (22:34 +0000)]
merge in euid generation from master

12 years agofirst working RSS collection with async DB-Saves
Wilfried Goesgens [Sun, 3 Jul 2011 13:49:59 +0000 (13:49 +0000)]
first working RSS collection with async DB-Saves

  - for now, no shorter URL expansion
  - replace handling of configs, old algorythm wasn't thread-safe
  - DB i/o is done in its own libev Queue in its own thread now; so we don't block network IO with database IO.

12 years agoAdd ability to hex encode binary strings
Wilfried Goesgens [Sun, 3 Jul 2011 13:47:55 +0000 (13:47 +0000)]
Add ability to hex encode binary strings

 - when encoding plain md5 binary buffers we have to pass the length into the hex encoder, add parameter
 - add wrapper providing old schematic
 - fix documentation of StrBufSipLine()

12 years agomore work on libevĀ“ing the rss-reader.
Wilfried Goesgens [Sat, 25 Jun 2011 07:12:46 +0000 (07:12 +0000)]
more work on libevĀ“ing the rss-reader.

12 years agofix loop / handling error when connecting fails immediately
Wilfried Goesgens [Mon, 6 Jun 2011 19:33:58 +0000 (19:33 +0000)]
fix loop / handling error when connecting fails immediately

  - add new ev_idle to unwind the stack on connecting
  - add a new handler that processes the disconnect

12 years agofix pointer indirections so we now can successfully fetch RSS feeds again.
Wilfried Goesgens [Sun, 5 Jun 2011 21:22:37 +0000 (21:22 +0000)]
fix pointer indirections so we now can successfully fetch RSS feeds again.

12 years agowhen not forking, we fail to drop rood privileges in advance before writing netconfig...
Wilfried Goesgens [Sun, 5 Jun 2011 21:20:17 +0000 (21:20 +0000)]
when not forking, we fail to drop rood privileges in advance before writing netconfig files, so we loose later access to them. Sadly we don't know our GID...

12 years agomove stuff out into own files from here...
Wilfried Goesgens [Sun, 5 Jun 2011 16:48:06 +0000 (16:48 +0000)]
move stuff out into own files from here...

12 years agoSplit RSS Parser...
Wilfried Goesgens [Sun, 5 Jun 2011 16:46:41 +0000 (16:46 +0000)]
Split RSS Parser...

  - URL-De-Shortener module
  - RSS/ATOM Handlers
  - start migrating to event/curl requests

12 years agoif specified, use our bind-ip for the http clients.
Wilfried Goesgens [Sun, 5 Jun 2011 16:44:59 +0000 (16:44 +0000)]
if specified, use our bind-ip for the http clients.

12 years agoGive us an own Context per notification client.
Wilfried Goesgens [Sun, 5 Jun 2011 16:42:29 +0000 (16:42 +0000)]
Give us an own Context per notification client.

12 years agorebuilt from .y
Wilfried Goesgens [Sun, 5 Jun 2011 16:41:39 +0000 (16:41 +0000)]
rebuilt from .y

12 years ago* make it const baby.
Wilfried Goesgens [Sun, 5 Jun 2011 15:28:24 +0000 (15:28 +0000)]
* make it const baby.

12 years agoFree all our allocated resources after notifying / sending a http request.
Wilfried Goesgens [Sun, 5 Jun 2011 13:49:09 +0000 (13:49 +0000)]
Free all our allocated resources after notifying / sending a http request.

12 years agofinish rewriting of http client code
Wilfried Goesgens [Mon, 30 May 2011 21:52:00 +0000 (21:52 +0000)]
finish rewriting of http client code

 - we now have a context
 - we now handle replies
 - still some uncertain cleanup condition.

12 years agoMigrate http context struct into the AsyncIO struct; streamline other structs.
Wilfried Goesgens [Sat, 21 May 2011 20:09:39 +0000 (20:09 +0000)]
Migrate http context struct into the AsyncIO struct; streamline other structs.

12 years agounlink global struct and request structs
Wilfried Goesgens [Sat, 21 May 2011 13:08:23 +0000 (13:08 +0000)]
unlink global struct and request structs

12 years agoFix unfolding of RFC822 lines so we don't loose blanks.
Wilfried Goesgens [Thu, 19 May 2011 21:19:25 +0000 (21:19 +0000)]
Fix unfolding of RFC822 lines so we don't loose blanks.

12 years agoDon't overwrite the 'TO' when sending mailinglist mails; we put ourselves into 'reply...
Wilfried Goesgens [Wed, 18 May 2011 21:35:30 +0000 (21:35 +0000)]
Don't overwrite the 'TO' when sending mailinglist mails; we put ourselves into 'reply to:'

12 years agoRewrite loading of notify configurations
Wilfried Goesgens [Sun, 15 May 2011 21:11:03 +0000 (21:11 +0000)]
Rewrite loading of notify configurations

12 years agosending http requests instant now.
Wilfried Goesgens [Sun, 15 May 2011 14:12:15 +0000 (14:12 +0000)]
sending http requests instant now.

12 years agowork on libev <-> libcurl integration
Wilfried Goesgens [Sun, 15 May 2011 10:43:11 +0000 (10:43 +0000)]
work on libev <-> libcurl integration

  - move libcurl handlers into the libev file; they need to be initialized to close to separate
  - add some logging;

First successfull CURL notification via libev!

12 years agoFix parsing and rearaning of URLs
Wilfried Goesgens [Sun, 15 May 2011 10:42:26 +0000 (10:42 +0000)]
Fix parsing and rearaning of URLs

12 years agodon't copy filedescriptors into the clone.
Wilfried Goesgens [Sat, 14 May 2011 14:28:50 +0000 (14:28 +0000)]
don't copy filedescriptors into the clone.

12 years agomore work on async http
Wilfried Goesgens [Sat, 14 May 2011 10:23:48 +0000 (10:23 +0000)]
more work on async http

12 years agoMemleak: free the vector of URLs to try to connect to.
Wilfried Goesgens [Sat, 14 May 2011 09:49:43 +0000 (09:49 +0000)]
Memleak: free the vector of URLs to try to connect to.

13 years agojust log the close if we're realy going to close.
Wilfried Goesgens [Tue, 10 May 2011 22:05:46 +0000 (22:05 +0000)]
just log the close if we're realy going to close.

13 years agoDon't close 0-filedescriptors on session killing, its our indicator for not here...
Wilfried Goesgens [Tue, 10 May 2011 22:03:20 +0000 (22:03 +0000)]
Don't close 0-filedescriptors on session killing, its our indicator for not here, since 0 equals STDIN which at best is redirected to /dev/null

13 years agouse long hash function, if we intend to use long values as keys, else we won't find...
Wilfried Goesgens [Mon, 9 May 2011 21:44:48 +0000 (21:44 +0000)]
use long hash function, if we intend to use long values as keys, else we won't find anything

13 years agoStop watchers / don't close 0
Wilfried Goesgens [Sun, 8 May 2011 17:43:46 +0000 (17:43 +0000)]
Stop watchers / don't close 0

13 years agowork on errorhandling for the smtp event client
Wilfried Goesgens [Sun, 8 May 2011 12:00:04 +0000 (12:00 +0000)]
work on errorhandling for the smtp event client

  - add states for the mx lookup phases
  - return the propper states
  - close filedescriptors if we fail one attempt
  - say which connection type we have: immediate, e_again, fail
  - say which NS-lookup whe do (a/aaaa)

13 years agoAdd backtrace debugging facility that doesn't add linebreaks
Wilfried Goesgens [Sun, 8 May 2011 11:58:27 +0000 (11:58 +0000)]
Add backtrace debugging facility that doesn't add linebreaks

13 years agolibevent needs to link the mathlib, so we add -lm
Wilfried Goesgens [Sun, 8 May 2011 11:53:34 +0000 (11:53 +0000)]
libevent needs to link the mathlib, so we add -lm

13 years agoups, .lo not .o
Wilfried Goesgens [Tue, 3 May 2011 20:11:46 +0000 (20:11 +0000)]
ups, .lo not .o

13 years agoadd prerelease so we don't get deinstalled all the time..
Wilfried Goesgens [Tue, 3 May 2011 19:55:11 +0000 (19:55 +0000)]
add prerelease so we don't get deinstalled all the time..

13 years agofix problem with po missing \n
Wilfried Goesgens [Tue, 3 May 2011 19:53:26 +0000 (19:53 +0000)]
fix problem with po missing \n

13 years agoWork on integrating libcurl <-> libev
Wilfried Goesgens [Tue, 3 May 2011 19:52:05 +0000 (19:52 +0000)]
Work on integrating libcurl <-> libev

13 years agoFix possible endless loop conditions
Wilfried Goesgens [Tue, 3 May 2011 19:49:23 +0000 (19:49 +0000)]
Fix possible endless loop conditions

13 years agoVarious cleanups of abort conditions
Wilfried Goesgens [Thu, 28 Apr 2011 19:20:52 +0000 (19:20 +0000)]
Various cleanups of abort conditions

  - if the timeout/connectionfail/... calls tell us to abort, shutdown the client
  - unregister all event structs

13 years agoName of MX in error messages
Wilfried Goesgens [Thu, 28 Apr 2011 19:10:56 +0000 (19:10 +0000)]
Name of MX in error messages

  - set it after successfull MX lookup
  - put in that we don't have an mx record if its NULL instead of 'no name'

13 years agofix gcc warning about it not knowing which pointer indirection is const...
Wilfried Goesgens [Thu, 28 Apr 2011 19:09:53 +0000 (19:09 +0000)]
fix gcc warning about it not knowing which pointer indirection is const...

13 years agoInclude ourselves??
Wilfried Goesgens [Tue, 19 Apr 2011 19:55:16 +0000 (19:55 +0000)]
Include ourselves??

13 years agoFix Crash
Wilfried Goesgens [Tue, 19 Apr 2011 19:50:55 +0000 (19:50 +0000)]
Fix Crash

  * check pointer before accessing it
  * fix probably uninitialized case

13 years agoGive event clients a citadel session context.
Wilfried Goesgens [Sat, 2 Apr 2011 15:56:18 +0000 (17:56 +0200)]
Give event clients a citadel session context.

13 years agoCleanup the event client struct, remove unused vars
Wilfried Goesgens [Sat, 2 Apr 2011 15:24:17 +0000 (17:24 +0200)]
Cleanup the event client struct, remove unused vars

13 years agojust use the ParsedURL to bear our destination address & port
Wilfried Goesgens [Sat, 2 Apr 2011 10:18:49 +0000 (12:18 +0200)]
just use the ParsedURL to bear our destination address & port

13 years agoUse IOBuffer with its StrBuf + const char* inside instead of having two of them
Wilfried Goesgens [Sat, 2 Apr 2011 09:26:07 +0000 (11:26 +0200)]
Use IOBuffer with its StrBuf + const char* inside instead of having two of them

13 years agoimplement abort handling
Wilfried Goesgens [Fri, 1 Apr 2011 21:48:57 +0000 (23:48 +0200)]
implement abort handling

13 years agoSwitch handling to have a pointer to the target address
Wilfried Goesgens [Fri, 1 Apr 2011 19:56:20 +0000 (21:56 +0200)]
Switch handling to have a pointer to the target address

 - change URL struct to contain sockaddr_in6
 - change URL-Parsing to add that indirection
 - change all pointer indirections so the new way fits

13 years agomove URL parsing / struct over into libcitadel
Wilfried Goesgens [Fri, 1 Apr 2011 14:51:48 +0000 (16:51 +0200)]
move URL parsing / struct over into libcitadel

13 years agoFix searching of ']'
Wilfried Goesgens [Thu, 31 Mar 2011 22:50:43 +0000 (00:50 +0200)]
Fix searching of ']'

13 years agoAdd busines logic for toggling multiple mx records etc.
Wilfried Goesgens [Thu, 31 Mar 2011 21:21:10 +0000 (23:21 +0200)]
Add busines logic for toggling multiple mx records etc.

 - move handlers into their own file
 - chain up stuff via URL-structs
(not yet all done)

13 years agoMailinglist client: don't add roomname to subject if its already there
Wilfried Goesgens [Thu, 31 Mar 2011 21:11:14 +0000 (23:11 +0200)]
Mailinglist client: don't add roomname to subject if its already there

13 years agofixing html2ascii
Wilfried Goesgens [Mon, 21 Feb 2011 22:13:33 +0000 (23:13 +0100)]
fixing html2ascii

  - add possibility to scan 4 digit entities
  - don't scan over the end
  - add tests

13 years agolibev migration: start out with creating support for 'fallbackhost'
Wilfried Goesgens [Thu, 3 Feb 2011 21:34:38 +0000 (22:34 +0100)]
libev migration: start out with creating support for 'fallbackhost'

13 years agolibev/c-ares migration; fix lookup chains
Wilfried Goesgens [Wed, 2 Feb 2011 20:34:49 +0000 (21:34 +0100)]
libev/c-ares migration; fix lookup chains

  - use idle-watchers for unwinding the c-ares stack (thanks to Marc Lehmann for the hint)
  - use the generic c-ares query & parse logic instead of the integrated call; we need to first do the a then fall back to the aaaa request which the c-ares default one doesn't implement
  - stop the shutdown watchers when finalizing one client

13 years agolibev migration - add shutdown handlers
Wilfried Goesgens [Mon, 31 Jan 2011 00:35:40 +0000 (01:35 +0100)]
libev migration - add shutdown handlers

  - this ties us to libev > 4.0
  - clean shutdown and storing of the new state in our quue

13 years agolibev migration: use async methods to schedule jobs. thanks to Marc Lehmann for the...
Wilfried Goesgens [Sun, 30 Jan 2011 23:10:11 +0000 (00:10 +0100)]
libev migration: use async methods to schedule jobs. thanks to Marc Lehmann for the friendly help.

13 years agolibev migration - copy valus we use for loop control before we hand it off into the...
Wilfried Goesgens [Sun, 30 Jan 2011 20:28:35 +0000 (21:28 +0100)]
libev migration - copy valus we use for loop control before we hand it off into the libevent queue

  - this fixes a race condition causing a double free with the to be copied mailpayload

13 years agoMerge branch 'libevent' of ssh://git.citadel.org/appl/gitroot/citadel into libevent
Wilfried Goesgens [Sun, 30 Jan 2011 14:29:59 +0000 (15:29 +0100)]
Merge branch 'libevent' of ssh://git.citadel.org/appl/gitroot/citadel into libevent

13 years agolibev/c-ares migration: unstack out ouf c-ares before querying new requests
Wilfried Goesgens [Sun, 30 Jan 2011 14:27:29 +0000 (15:27 +0100)]
libev/c-ares migration: unstack out ouf c-ares before querying new requests

  - we use the c-ares callback to parse the DNS reply and put the reply to our callback
  - we then set a zero-timer with the call to continue our flow
  - we return / unstack c-ares
  - we then do the a/aaaa record lookup without having another ares lookup in our stack
this circumvents double dns lookups.

13 years agoQP-Decoding: Ignore case of letter indicating _B_inary or _Q_uoted printeable, there...
Wilfried Goesgens [Sun, 30 Jan 2011 12:14:05 +0000 (13:14 +0100)]
QP-Decoding: Ignore case of letter indicating _B_inary or _Q_uoted printeable, there seem to be solutions around sending q,b instead of Q,B

13 years agoby jimcuclamath: use defines instead of numbers for logging; Change some loglevels...
Wilfried Goesgens [Sun, 30 Jan 2011 11:12:44 +0000 (12:12 +0100)]
by jimcuclamath: use defines instead of numbers for logging; Change some loglevels to DEBUG

13 years agofix ipv6 connections in smtp client
Wilfried Goesgens [Tue, 25 Jan 2011 22:51:22 +0000 (23:51 +0100)]
fix ipv6 connections in smtp client

13 years agofix IPv6 relay url parsing
Wilfried Goesgens [Tue, 25 Jan 2011 20:15:25 +0000 (21:15 +0100)]
fix IPv6 relay url parsing

13 years agolibev migration: check pointer before free'ing it.
Wilfried Goesgens [Mon, 24 Jan 2011 23:22:49 +0000 (00:22 +0100)]
libev migration: check pointer before free'ing it.

13 years agolibev migration / c-ares migration
Wilfried Goesgens [Sun, 23 Jan 2011 22:10:51 +0000 (23:10 +0100)]
libev migration / c-ares migration

  - free c-ares structs and its watchers in appropriate places
  - finalize relaying

13 years agolibev migration; relaying implementation
Wilfried Goesgens [Sun, 23 Jan 2011 19:21:20 +0000 (20:21 +0100)]
libev migration; relaying implementation

  - move translation of DNS-results up into the SMTP-Client
  - use an own callback for connecting to IP-based relays
  - add assertions to callbacks being NULL, since after callin a NULL-callback the last stackframe is NIL and Void, and we can't see where we went off into misery.

13 years agolibev migration: reinstantiate MX-Relay; unfinished.
Wilfried Goesgens [Thu, 20 Jan 2011 23:20:07 +0000 (00:20 +0100)]
libev migration: reinstantiate MX-Relay; unfinished.

13 years agolibev migration: remove 127.0.0.1 forcing
Wilfried Goesgens [Sun, 16 Jan 2011 17:49:33 +0000 (18:49 +0100)]
libev migration: remove 127.0.0.1 forcing

13 years agoLibev migration:
Wilfried Goesgens [Sun, 16 Jan 2011 17:46:56 +0000 (18:46 +0100)]
Libev migration:

  - timeouts implemented & working
  - async connects working

13 years agolibev migration - timeouts seem to be working.
Wilfried Goesgens [Sat, 15 Jan 2011 19:57:34 +0000 (20:57 +0100)]
libev migration - timeouts seem to be working.

  - handle timeouts with libev timers

13 years agolibev migration; cleanup bounce; use libev to get the current time.
Wilfried Goesgens [Sat, 15 Jan 2011 18:10:48 +0000 (19:10 +0100)]
libev migration; cleanup bounce; use libev to get the current time.

13 years agouse the gnu format string checker for CtdlLogPrintf; fix associated new warnings...
Wilfried Goesgens [Sat, 15 Jan 2011 17:47:03 +0000 (18:47 +0100)]
use the gnu format string checker for CtdlLogPrintf; fix associated new warnings / problems.

13 years agoLibev migration Cleanup, print resolved IP to log
Wilfried Goesgens [Sat, 15 Jan 2011 16:21:16 +0000 (17:21 +0100)]
Libev migration Cleanup, print resolved IP to log

13 years agoLibev Migration; fix aborting on connection establishing problems
Wilfried Goesgens [Sat, 15 Jan 2011 15:18:10 +0000 (16:18 +0100)]
Libev Migration; fix aborting on connection establishing problems

  - libev doesn't care whether a watcher is already registered or not, we don't need to remember which to stop and which not.
  - cast to the right structure while aborting
  - put timeout callback in
  - register timeout callback
  - close our socket in the right place.

13 years agoFix bouncing of messages in smtp-queue
Wilfried Goesgens [Sat, 15 Jan 2011 15:16:43 +0000 (16:16 +0100)]
Fix bouncing of messages in smtp-queue

  - free boundary when barfing out
  - put the message body on the right citadel message collumn

13 years agoMimeparser rewrite; fix bug detecting trailing MIME-Boundary
Wilfried Goesgens [Sat, 15 Jan 2011 15:14:16 +0000 (16:14 +0100)]
Mimeparser rewrite; fix bug detecting trailing MIME-Boundary

  - when searching for the '--' after the mime boundary to detect whether its the last, we had an off by one. fixed.

13 years agolibev migration - fix queue conditions
Wilfried Goesgens [Sat, 15 Jan 2011 10:45:46 +0000 (11:45 +0100)]
libev migration - fix queue conditions

  - handle messages without recipients
  - remove the the original message when we finished our job.