Commit Graph

80 Commits

Author SHA1 Message Date
Christian Neukirchen
8629e12ee6 rfc2047: revert in blaze822_decode_b64 2016-07-15 16:39:23 +02:00
Christian Neukirchen
010458d971 rfc2047: try sliced version of blaze822_decode_b64 (no benefit in practise) 2016-07-15 16:38:48 +02:00
Christian Neukirchen
de84495a55 next: fix mmap error detection 2016-07-15 16:09:08 +02:00
Christian Neukirchen
00b0e23f1f rfc2047: blaze822_decode_b64: check bounds 2016-07-14 18:24:08 +02:00
Christian Neukirchen
15016ba4ca slay more warnings 2016-07-14 18:21:38 +02:00
Christian Neukirchen
bc9d79606b fix printf format codes 2016-07-14 18:21:07 +02:00
Christian Neukirchen
b56f2a668b add () for assignments 2016-07-14 18:20:42 +02:00
Christian Neukirchen
8c7c614bb3 Makefile: drop -Wwrite-strings 2016-07-14 18:20:12 +02:00
Christian Neukirchen
1a1f01ecf9 rfc2047: blaze822_decode_qp: check bounds 2016-07-14 17:43:09 +02:00
Christian Neukirchen
8b8f391052 hdr: use -HEADER to only display the header, else print all headers 2016-07-14 15:40:57 +02:00
Christian Neukirchen
54f695dddf blaze822: iterate over headers 2016-07-14 15:40:48 +02:00
Christian Neukirchen
ff7771d4fb remove some obsolete stuff 2016-07-14 15:25:26 +02:00
Christian Neukirchen
f101b728d9 blaze822: add mmap-based mail reader 2016-07-14 15:21:37 +02:00
Christian Neukirchen
13eefbba72 rfc2045: return 0 when no body is found in blaze822_mime_body 2016-07-14 15:20:59 +02:00
Christian Neukirchen
7b6436797c blaze822: remaining fixes in new loop 2016-07-14 14:09:50 +02:00
Christian Neukirchen
1ff1ff3dd0 blaze822: avoid overflow in blaze822_hdr_ 2016-07-14 13:27:14 +02:00
Christian Neukirchen
266b904897 blaze822: rewrite inner loop
Do nul and crlf clean up first, only when required.
Replace line-detection loop with strchr.
2016-07-13 23:50:06 +02:00
Christian Neukirchen
aad1e02178 unmime: free some things
Not 100% precise yet.
2016-07-13 21:56:47 +02:00
Christian Neukirchen
e57d1b3192 rfc2045: new parameter for blaze822_mime_body to allow freeing of new chunk 2016-07-13 21:56:16 +02:00
Christian Neukirchen
4798cb386e blaze822: allow freeing of null pointers 2016-07-13 21:55:17 +02:00
Christian Neukirchen
005037e254 blaze822: blaze822_mem: use body=bodyend instead of body=0
Else we lose track of where we are during multipart when there is no
body (really a body of length 0).
2016-07-13 21:35:42 +02:00
Christian Neukirchen
f122c3c7d2 rfc2045: blaze822_mime_body: zero output fields when no body is there 2016-07-13 21:34:46 +02:00
Christian Neukirchen
411c9b632a blaze822: detect too short/empty headers 2016-07-13 21:08:05 +02:00
Christian Neukirchen
11c9ce78f1 rfc2047: blaze822_decode_qp: off-by-one in qp decoding 2016-07-13 20:53:26 +02:00
Christian Neukirchen
42677a0586 rfc2045: blaze822_multipart: \0 also terminates boundary 2016-07-13 20:50:48 +02:00
Christian Neukirchen
d0d371114c blaze822: compression fixes 2016-07-13 20:32:44 +02:00
Christian Neukirchen
d687378b62 blaze822: give in and actually unfold the lines 2016-07-13 18:00:09 +02:00
Christian Neukirchen
91e83c5ee8 show: free message at end 2016-07-13 17:18:16 +02:00
Christian Neukirchen
a96fb5c5ee scan: free message at end 2016-07-13 17:18:06 +02:00
Christian Neukirchen
6e6d1993a2 rfc2047: free all things in blaze822_decode_rfc2047 2016-07-13 17:17:43 +02:00
Christian Neukirchen
00954008cc blaze822: free line in blaze822_loop 2016-07-13 17:17:18 +02:00
Christian Neukirchen
39006b8c89 blaze822: off by one in blaze822_mem 2016-07-13 17:02:29 +02:00
Christian Neukirchen
5e149c5732 show: better iterator 2016-07-13 17:02:17 +02:00
Christian Neukirchen
d3080b92d3 scan: print line number 2016-07-13 16:47:24 +02:00
Christian Neukirchen
797ddf96dc next: plain numbers are now absolute, use +/- prefix for relative 2016-07-13 16:47:06 +02:00
Christian Neukirchen
105f520c7e thread: try to keep relative order from input 2016-07-13 16:13:29 +02:00
Christian Neukirchen
435d5a5a89 rfc2045: fix crlf after boundary 2016-07-13 16:05:31 +02:00
Christian Neukirchen
5b84593e78 blaze822: fix blaze822_mem body start 2016-07-13 16:03:35 +02:00
Christian Neukirchen
6b639da842 blaze822: fix blaze822_file return value on error 2016-07-13 16:03:16 +02:00
Christian Neukirchen
b32ef0fd5a blaze822_priv.h: add isfws 2016-07-13 16:00:20 +02:00
Christian Neukirchen
8ba55bae99 blaze822_priv.h: macro cleanup 2016-07-13 15:56:50 +02:00
Christian Neukirchen
01c1c0d970 add rfc2045 and multipart decoding 2016-07-13 15:53:27 +02:00
Christian Neukirchen
0e892a5d83 show: fix api usage 2016-07-13 15:52:52 +02:00
Christian Neukirchen
17355dbe63 blaze822: api refactoring 2016-07-13 15:52:39 +02:00
Christian Neukirchen
7c0663e0e5 blaze822: don't prefix first header with nul bytes
Instead, look for the first header as a special case.
This allows us to parse a header as-is without shifting in memory.
2016-07-13 15:22:47 +02:00
Christian Neukirchen
0552c3708e scan: tweak date formatting 2016-07-13 15:04:04 +02:00
Christian Neukirchen
dab7da7bbc blaze822: parsing of in-memory messages 2016-07-13 15:01:38 +02:00
Christian Neukirchen
19ba414abc blaze822: header cleanup 2016-07-13 15:01:09 +02:00
Christian Neukirchen
5bc288f1aa blaze822: hackfix 2016-07-12 21:11:18 +02:00
Christian Neukirchen
9418394d14 next: add offset, also negative 2016-07-12 20:43:44 +02:00